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

The value of empty should display as empty #7

Open
yardsale8 opened this issue Oct 28, 2014 · 1 comment
Open

The value of empty should display as empty #7

yardsale8 opened this issue Oct 28, 2014 · 1 comment

Comments

@yardsale8
Copy link

When you evaluate empty you get '() displayed.

> empty
- (listof 'a)
'()

But '() evaluates to the empty s-expression.

> '()
- s-expression
'()

This causes problems with pasting and interpreting values, especially empty lists of various types.

@mflatt
Copy link
Owner

mflatt commented Oct 28, 2014

I agree that this is awkward, but I don't see a way around it without creating other problems. It's one of the compromises made for the s-expression type, whose values (and therefore printed forms) overlap with those of other types.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants