Bro i think .. vairables can only be on stack or data/bss ... because .... variables need to change frequently ... and .txt segment is just xecutale not writable... on other hand .. data/bss or stack are writable ...
Hello!
I learned at least 2 ways to put variable in code.
The first one is via pointers, and the second one is with the help of "allocate" directive.
If need to write something in code section we can use VirtualProtect or #pragma to make this possible.
Note: Registration is required to post to the forums.