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

Fix issue 246 #247

Merged
merged 3 commits into from
Dec 4, 2022
Merged

Fix issue 246 #247

merged 3 commits into from
Dec 4, 2022

Conversation

kubo
Copy link
Contributor

@kubo kubo commented Jun 28, 2022

Close #246

This pull request consists of three commits.

  1. The first commit adds the following method to Parser and use it in the parse_expression method with two arguments.

    std::shared_ptr<ExpressionNode> parse_expression(Template& tmpl)

    The method with one argument returns when unexpected token is found.

  2. The second fixes function(num1 + num2, num3) seems to run as if it is function(num1, num2 + num3) #246. parse_expression with one argument is called recursively for each argument.

  3. The third is optional. If you don't prefer it, I'll revert it. It calls parse_expression with one argument after a left parenthesis instead of counting the nested level by current_paren_level.

@pantor pantor merged commit d462b9f into pantor:master Dec 4, 2022
@pantor
Copy link
Owner

pantor commented Dec 4, 2022

Thanks for the fix and for your patience!

@kubo kubo deleted the fix-issue-246 branch November 17, 2024 02:20
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.

function(num1 + num2, num3) seems to run as if it is function(num1, num2 + num3)
2 participants