-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
MatchError: NoPrefix() when printing code of the NoPrefix() type #19905
Comments
I would go against printing A more useful error message seems to be the solution. |
I dunno, making a method take a Type and return a string, then typecheck and blow up at runtime because it's the "wrong kind of Type" also sounds like a good way to hide bugs. If we, hypothetically, end up with some library or user code that decomposes a type and constructs a string incorrectly, such as passing a NoPrefix prefix, then they'll realise if they ever care to look at the result, I would think. |
Compiler version
3.3.3
3.4.0
3.4.1-RC1
3.4.2-RC1-bin-20240308-18645ee-NIGHTLY
Minimized code
Macro definitions
Macro use
Output
Expectation
Printing
NoPrefix
should either"<no-prefix>"
); orNoPrefix
.The text was updated successfully, but these errors were encountered: