Hello group,
Why are the following snippets errors?
syntax error: unexpected == at end of statement
switch S{i: 0} == S{} {
}
syntax error: unexpected i, expecting case or default or }
It works without error if you surround each literal with ( ), or the entire comparison expression with ( ).
The following also works without error:
Does the language spec state those are errors, or is this a bug in the parser?
Thanks!