-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
consistent use of scForceOpen for generic dot field symbols #21738
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This should be good to go. It's pretty straightforward, if we use The ambiguous |
compiler/semgnrc.nim
Outdated
@@ -58,15 +58,22 @@ template isMixedIn(sym): bool = | |||
|
|||
proc semGenericStmtSymbol(c: PContext, n: PNode, s: PSym, | |||
ctx: var GenericCtx; flags: TSemGenericFlags, | |||
fromDotExpr=false): PNode = | |||
fromDotExpr: static bool = false): PNode = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does this have to be static bool
? The code duplication is likely worse than a runtime check which is predicted correctly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't have to be, I thought since it's a small proc and called tons of times it might be better, but it's non-essential, changing it back
It breaks tests/js/tdiscard.nim ? Not sure. |
CI was fine before and it only broke on osx cpp, must have been bitflip/IO error Chronos error should also be unrelated, maybe temporary server outage Could rebase to be safe |
fixes nim-lang#21724 but might break code
3611a19
to
6a06075
Compare
CI is fine now |
Thanks for your hard work on this PR! Hint: mm: orc; opt: speed; options: -d:release |
…#21738) * always force open generic dot field symbols? fixes nim-lang#21724 but might break code * alternative, should fix CI * other alternative, add test for previous CI failure * not needed * make sure call doesn't compile too * ok actual second test * ok final actual correct test * apply performance idea * don't make fromDotExpr static
…#21738) * always force open generic dot field symbols? fixes nim-lang#21724 but might break code * alternative, should fix CI * other alternative, add test for previous CI failure * not needed * make sure call doesn't compile too * ok actual second test * ok final actual correct test * apply performance idea * don't make fromDotExpr static
* always force open generic dot field symbols? fixes #21724 but might break code * alternative, should fix CI * other alternative, add test for previous CI failure * not needed * make sure call doesn't compile too * ok actual second test * ok final actual correct test * apply performance idea * don't make fromDotExpr static (cherry picked from commit e92d768)
* always force open generic dot field symbols? fixes #21724 but might break code * alternative, should fix CI * other alternative, add test for previous CI failure * not needed * make sure call doesn't compile too * ok actual second test * ok final actual correct test * apply performance idea * don't make fromDotExpr static (cherry picked from commit e92d768)
…#21738) * always force open generic dot field symbols? fixes nim-lang#21724 but might break code * alternative, should fix CI * other alternative, add test for previous CI failure * not needed * make sure call doesn't compile too * ok actual second test * ok final actual correct test * apply performance idea * don't make fromDotExpr static
fixes #21724