-
Notifications
You must be signed in to change notification settings - Fork 65
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
Use of string concatenation rather than variable interpolation? #60
Comments
@con-mo8 No specific preference. |
Though I definitely understand the concern for proper highlighting, I also wanted to add that technically in the example you gave @hankache you don't even need curlies as a simple That being said, even my perl6fe language highlighter doesn't catch this style of interpolation (though it is planned). |
@hankache not sure it helps but the latest vim highlighter does fully support string interpolation amongst other more Perl 6 specific syntax. |
@con-mo8 Unfortunately, asciidoctor supports only pygments and highlight.js. In addition pygments is the only one that does support Perl 6 highlighting. |
@hankache unfortunately highlight.js doesn't support heredocs but otherwise I'm almost finished with Perl 6 support for it. I've been looking at SyntaxHighlighter which utilizes XRegexp and that has the ability to do named captures (for supporting heredocs) so I will probably do a plugin for that next. Another option is GitHub's Highlights as that way you could directly utilize my language-perl6fe grammar, but I don't know how easy that would be to integrate into asciidoctor, I did a cursory look and I don't think anyone's tried it before. |
A final option would be to beef up Pygments' Perl 6 lexer! I'll take a look and see what can be done there too as I've written a Pygments lexer before. |
@MadcapJake Please do tell me if you manage to do one of the above, so I can test them on perl6intro. |
@samcv is doing a great job on https://github.com/perl6/atom-language-perl6 |
@hankache you probably know I converted the docs site to use highlights, so it may be possible. |
@samcv pygments |
One of the core advantages of Perl 6 over Perl 5 for me is how advanced variable interpolation is in quoting. For some reason most of perl6intro prefers "" ~ value ~ "" which I find kind of messy. Is there a strong preference for this? Or am I ok to go through and change these where appropriate? For example
say "The capital of France is: %capitals<France>"
works perfectly well. More complex expressions I'd prefer "{ expression }" to "" ~ expression ~ "". I'd reserve ~ for something more like $str1 ~ $str2 where there is no default quote construct to be included.The text was updated successfully, but these errors were encountered: