-
-
Notifications
You must be signed in to change notification settings - Fork 63
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
error while compiling when a source file starts with a number #259
Labels
Comments
The filename is used as a prefix for generated identifiers, so it has to be an identifier itself. "Has to be", but invalid characters are replaced with X. A simple fix ix probably to have that replacement include leading numerals. There is a workaround: ## pragmas.unitname = 'eightball'
local function f()
print 'from 8ball.nelia'
end
f() This works as it generates |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug description
i was trying out using Nelua with an 8ball program, and by the end of it named it accordingly,
8ball.nelua
, and it threw this compiler errorCode example
no code for example, compiler issue
Expected behavior
the compilation finishes successfully and runs the code
Workaround
if you were to rename the file to
eightball.nelua
, or something else without a number the compilation will finish successfullyEnvironment
Nelua 0.2.0-dev
Build number: 1615
Git date: 2024-04-20 09:45:08 -0300
Git hash: 9f75e00
Semantic version: 0.2.0-dev.1615+9f75e009
Copyright (C) 2019-2024 Eduardo Bart (https://nelua.io/)
Linux
x86_64
gcc (Debian 12.2.0-14) 12.2.0
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
The text was updated successfully, but these errors were encountered: