Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify absent sequences and records with empty ones #660

Open
jyasskin opened this issue Jun 22, 2023 · 0 comments
Open

Unify absent sequences and records with empty ones #660

jyasskin opened this issue Jun 22, 2023 · 0 comments
Labels
spec Relates to the spec

Comments

@jyasskin
Copy link
Member

In many, but not all cases, an absent sequence or record argument is equivalent to an empty one. The spec should be clear about when that is or isn't the case. When they are equivalent, the sequence or record should be defaulted to empty in order to reduce the number of states the specification has to deal with.

For sequences, we can use =[] in the dictionary definition to set the default value. For records, I don't think ={} works, but we can do it the first time those members are read or by setting the initial value of the struct they're copied into.

@JensenPaul JensenPaul added the spec Relates to the spec label Jun 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
spec Relates to the spec
Projects
None yet
Development

No branches or pull requests

2 participants