Handle walrus operator

Or rather set precedence on call_stmt and expr_stmt

Adjust pytest test_single_compile so it works now
This commit is contained in:
rocky
2022-04-12 05:21:13 -04:00
parent e7fd592313
commit a1fe069c8c
7 changed files with 104 additions and 70 deletions

Binary file not shown.

View File

@@ -0,0 +1,14 @@
# From 3.8 test_named_expressions.py
# Bug was not putting parenthesis around := below
# RUNNABLE!
"""This program is self-checking!"""
(a := 10)
assert a == 10
# Bug was not putting all of the levels of parentheses := below
(z := (y := (x := 0)))
assert x == 0
assert y == 0
assert z == 0