-
Notifications
You must be signed in to change notification settings - Fork 190
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
Setting delimiters to the current delimiters causes error #38
Comments
Could you please provide a short template that exhibits the problem, and the error message? |
This produces an error: "Parse error at line 1: Unclosed Mustache tag"
This produces no error
This produces the same error, so it seems to occur when you try to set the delimiters to what they already are:
|
Yes, indeed. The implementation of the parser doesn't like an opening token to be between an opening and a closing one, as in Are those templates machine-generated? |
Kind of. The implementation I'm working on is being able to run through the same template a couple times with different delimiters each time by wrapping the template after each pass through in a string format delimiter change. Edit: It's not really a big deal as I can always check before wrapping it, but it seems like a bug nonetheless. |
Yes, it seems like a bug. A pull request will be welcome, if you feel like fixing it. |
Actually I don't know where the bug is, in GRMustache, in the Mustache (non-specified) grammar, or in the "set delimiters tags" concept. I'm closing this issue as "won't fix". Handlebars got rid of delimiter tags, and replaced them with backslash escaping. I tend to think it's a superior solution. @Psybert, would you live if delimiters tags were replaced by backslash escaping of braces? |
Well I'll be using the set delimiters feature, but the backslash escaping seems to be pretty powerful as well. |
Reopening |
This issue has been reopened because it will be solved when #45 gets fixed in the master branch. |
Fixed in v6.7.2. |
When setting the delimiter to the original value when it's currently set to the original value causes an error.
The text was updated successfully, but these errors were encountered: