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

test unlocking paramTypesMatch for templates and macros #23176

Draft
wants to merge 8 commits into
base: devel
Choose a base branch
from

Conversation

metagn
Copy link
Collaborator

@metagn metagn commented Jan 6, 2024

fixes #18667

Chronos failure is likely caused by sink T here

Normalize: this needs to use var int32 - done

Note: #5030, #12780, #21813, #22881 should have been fixed but maybe weren't if I didn't mention them, related #2459 probably not fixed here because tyOpenArray is disabled

Araq pushed a commit to nim-lang/db_connector that referenced this pull request Jan 6, 2024
By default the type `proc (s: string): string` assumes {.closure.}, but the uses of `dbFormatImpl` only refer to implementations of `dbQuote` in each module which are good enough as {.nimcall.}.

Normally this doesn't matter, but if the rules of how template arguments are converted to argument types change to match normal procs in Nim in the future (as experimented in nim-lang/Nim#23176), the passed `dbQuote` will be treated as an implicit conversion from a {.nimcall.} proc into a {.closure.} proc, which causes the effect tracker to treat it as an arbitrary procvar and assume it causes `RootEffect`. This won't necessarily be a problem but we can guard against it for the time being.
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.

can't pass @[] to template (even typed) => internal error or sigmatch error
1 participant