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

false positive deprecation warning printed for converter that is not actually used #24241

Closed
arnetheduck opened this issue Oct 5, 2024 · 0 comments · Fixed by #24243
Closed

Comments

@arnetheduck
Copy link
Contributor

Description

type X = distinct int

converter toInt(x: X): int{.deprecated.} = int(x)

template `==`(a, b: X): bool = false # this gets called so we didn't convert

assert not (X(1) == X(2))

Nim Version

2.0.8

Current Output

testit.nim(7, 14) Warning: toInt is deprecated [Deprecated]
testit.nim(7, 22) Warning: toInt is deprecated [Deprecated]

Expected Output

no warnings

Known Workarounds

No response

Additional Information

No response

metagn added a commit to metagn/Nim that referenced this issue Oct 5, 2024
@Araq Araq closed this as completed in 09043f4 Oct 6, 2024
narimiran pushed a commit that referenced this issue Oct 8, 2024
arnetheduck added a commit to status-im/nim-eth that referenced this issue Oct 29, 2024
The warning gives too many false positives - until things work properly,
locally one can just remove it to find instances where it gets used..

nim-lang/Nim#24241
arnetheduck added a commit to status-im/nim-eth that referenced this issue Oct 30, 2024
The warning gives too many false positives - until things work properly,
locally one can just remove it to find instances where it gets used..

nim-lang/Nim#24241
narimiran pushed a commit that referenced this issue Jan 14, 2025
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 a pull request may close this issue.

1 participant