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

fixes #12747 [backport] #13651

Merged
merged 4 commits into from
Mar 16, 2020
Merged

fixes #12747 [backport] #13651

merged 4 commits into from
Mar 16, 2020

Conversation

cooldome
Copy link
Member

No description provided.

@@ -563,7 +563,7 @@ proc putArgInto(arg: PNode, formal: PType): TPutArgInto =
return paDirectMapping # XXX really correct?
# what if ``arg`` has side-effects?
case arg.kind
of nkEmpty..nkNilLit:
of nkEmpty..nkNilLit, nkDotExpr:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if it's sideEffectHere().field? Then we cannot use a direct mapping, can we?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, fixed

@cooldome
Copy link
Member Author

I have also added nkObjConstr handling as well and also noticed that nkExprColonExpr is not handled for nkPar, nkTupleConstr.

@Araq Araq closed this Mar 16, 2020
@Araq Araq reopened this Mar 16, 2020
@Araq
Copy link
Member

Araq commented Mar 16, 2020

Please rebase

@cooldome
Copy link
Member Author

Ready for review

@Araq Araq merged commit 613ea6e into nim-lang:devel Mar 16, 2020
narimiran pushed a commit that referenced this pull request Apr 14, 2020
* fixes #12747
* fix tests
* improve code style

Co-authored-by: cooldome <[email protected]>
(cherry picked from commit 613ea6e)
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.

3 participants