Skip to content

Tuple assigments fail in short-circuit evaluations #56770

Closed as not planned
Closed as not planned
@subthedubdub

Description

begin
	# valid
	x,y = 1,1
	# valid
	x,y  = (2,2)
	# valid
	true && (x,y = (3,3) )
	# invalid
	true && (x,y = 4,4)
end

The last assignment gives the following error:

ERROR: syntax: invalid named tuple element "4"

I don't think this is the intended parsing behavior.

Tested on 1.11.1 on Linux/amd64.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    invalidIndicates that an issue or pull request is no longer relevantparserLanguage parsing and surface syntax

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions