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

Treat literals as special cases when parsing #434

Merged
merged 5 commits into from
Apr 2, 2017
Merged

Conversation

Rich-Harris
Copy link
Member

Alternative to #426

@Conduitry
Copy link
Member

Conduitry commented Apr 2, 2017

This seems reasonable - but the literals should probably be a map, not an object, otherwise anything in Object.prototype would also be seen as a literal. Because of the all-lowercase regex check, I guess all that would affect is {{constructor}}, which would always be interpreted as a literal equal to Object.prototype.constructor, instead of (possibly) whatever other value it should.

@Rich-Harris
Copy link
Member Author

Good point! I always forget that I can use Map. Old habits.

@Conduitry
Copy link
Member

LGTM 👍

@Rich-Harris Rich-Harris merged commit 67d6eb8 into master Apr 2, 2017
@Rich-Harris Rich-Harris deleted the gh-424-alt branch April 2, 2017 13:54
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

Successfully merging this pull request may close these issues.

2 participants