It is not syntactic sugar, "x := 10" is an assignment expression in contrast with "x = 10", which is a statement. Hence the former can be used in contexts like "if x := 10: pass", which is the whole point of the PEP.
It is not syntactic sugar, "x := 10" is an assignment expression in contrast with "x = 10", which is a statement. Hence the former can be used in contexts like "if x := 10: pass", which is the whole point of the PEP.