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

Explicit declaration of Vector for iteration does not compile #59

Closed
drahnr opened this issue Oct 20, 2017 · 3 comments
Closed

Explicit declaration of Vector for iteration does not compile #59

drahnr opened this issue Oct 20, 2017 · 3 comments

Comments

@drahnr
Copy link
Contributor

drahnr commented Oct 20, 2017

{% for x in ["a", "b"] %}
{{ x }}
{% endfor %}

nor

{% let xes = ["a", "b"] %}
{% for x in xes %}
{{ x }}
{% endfor %}

works, which would be intuitively what I'd want to do.

This is mostly for shortening a template where huge parts are redundant, but do not need to be adjustable from within the binary.

@djc djc closed this as completed in 4af73a8 Oct 20, 2017
@djc
Copy link
Owner

djc commented Oct 20, 2017

Thanks for the report! I've fixed this, so it should work with latest master.

@drahnr
Copy link
Contributor Author

drahnr commented Oct 21, 2017

There is one special case which is not working yet:

["", "pr-"]

@djc
Copy link
Owner

djc commented Oct 22, 2017

Right, the empty string was not handled correctly. Should be fixed with 14beb21.

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