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

Detect String and RegExp Interpolation #2

Closed
netzpirat opened this issue Sep 17, 2010 · 4 comments
Closed

Detect String and RegExp Interpolation #2

netzpirat opened this issue Sep 17, 2010 · 4 comments

Comments

@netzpirat
Copy link

It would be very nice if String and RegExp interpolation would be detected and thus correctly colorized.

Example

aString = "This is a interpolation #{ @generatedText() } within a string"

aRegExp = /\d+#{ @separator }\d+#{ @separator }\d+/g
@PandaWood
Copy link

And for the new /// regex heredocs syntax as well

@netzpirat
Copy link
Author

I have now both implemented in CoffeeBrew

@PandaWood
Copy link

BTW I tried using interpolation for single regex '/' (as you have in this comment) on coffee-script v1.0 and it didn't compile. So I gather you can only use interpolation for heredoc regex '///'.

@netzpirat
Copy link
Author

You are right. CoffeeScript allows interpolation only within a heregex and not within a normal regex. Thanks for pointing that out.

This issue was closed.
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