-
-
Notifications
You must be signed in to change notification settings - Fork 757
Silent failure - no idea #5085
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
Comments
to clarify, it still outputs a .exe file, it just dont run it. It seems something goes wrong before main. |
Update it works if I do:
that is if it is not a pointer |
Try running the generated executable and What makes you think "something goes wrong before main" if you're talking about changing something in |
Where does that Sounds like you're doing something like this: new_host :: proc(width, height: int) -> ^Host_data {
host := Host_data {
terrain = generate_terrain(width, height),
}
return &host
}
main :: proc() {
host := new_host(13, 42)
destroy(host)
} That works until you change your log statement or something else, reordering the stack layout in the process, and overwriting the data returned by |
Its not a stack corruption as the function is never called, the values are also correct if printed sperately. I dont know if this helps, but these are all the function which are involved with getting there. The project is big, like 55k lines, so i have a hard time pinning down issue. I belive it failes before main because i dont get to main when the program is executed. Ok, so this is how it works:
|
ok, i ran it in a debugger the issue was a completely different place.
|
Ah, |
this code had been there for like months, i dont know why i did not run into this before XD |
Uh oh!
There was an error while loading. Please reload this page.
Context
I am experiencing a silent run failure, it failes without any messages.
I can build the project, but when i run it nothing happens.
Observe:
Expected Behavior
It should run
Current Behavior
It just dont do anything
Steps to Reproduce
I am not sure, here is what i got:
I have this function:
if i remove the line:
then it runs, but notice that the code here is never executed.
If i do:
Then it still DOES NOT RUN!
I can print the members just fine, so if i do:
But not if i print host_data itself.
I have tried renaming host_data, it does not help.
I have tried removing using, it does not help
I have tried with fmt.printf and aprintf instead of log, it does not help.
I can print all of the member one by one, but not together, that is this works:
but this does not:
I have no idea what would cause this
The text was updated successfully, but these errors were encountered: