Closed ghost closed 7 years ago
That is weird, since when I try that (placing it in global scope), I get this:
file.c
Numbers__Int MY_VAR;
file-fwd.h
extern Numbers__Int MY_VAR;
and then in file_load()
MY_VAR = -1;
Thanks, I will try that again on the same files I tried before and let you know.
Created a specific issue for variables defined inside a version block. #77
I would like to do something like
Where in .ooc file should I place the definition of
MY_VAR: unmangled Int = -1
? Placing it in the global scope seems to generate only a local variable in the module'sload
function:I guess I could add a plain .c file with just the variable definition (or use unmangled function to return the value), but it seems like easy enough task to be solved via "pure" ooc. And I'm also curious if / how it's possible.