That’s a nice idea. You can always put a pointer there if you need more state.
It just doesn’t work on machines with different int and pointer sizes. On the benefit of interoperability, I suggest you make it a (void*). So one function can set it program_state = (void*)'K'; while some other one can set it program_state ={1, 32, 768}; and yet another can do program_state = "I'm in the middle of something here!";.
That’s a nice idea. You can always put a pointer there if you need more state.
It just doesn’t work on machines with different int and pointer sizes. On the benefit of interoperability, I suggest you make it a (void*). So one function can set it
program_state = (void*)'K';while some other one can set itprogram_state ={1, 32, 768}; and yet another can doprogram_state = "I'm in the middle of something here!";.