basic Python porting to Mojo #3329
-
I got out of ideas when I got this error. I'm simply trying to take my python code (just the argument/option handling part of it) and port to Mojo, which is when I got the above error.
and
|
Beta Was this translation helpful? Give feedback.
Answered by
soraros
Jul 30, 2024
Replies: 1 comment 3 replies
-
Could you maybe share your code? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In Mojo, a string literal (
"something"
) has the typeStringLiteral
(this is about to change to match Python). They can't be concatenated at compile time. The fix is simple: convert them toString
as follows:Perhaps the error message is less helpful on version 24.4 (I don't have it installed), but the error on the nightly build reads: