Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

C dynamic structure

Name: Anonymous 2011-12-05 10:24

Something I've been wondering,

Is it possible at runtime to dynamically create a struct? I don't mean dynamic array size, I mean the variables and such inside a structure.

Name: Anonymous 2011-12-05 10:26

I do not know if there is a simpler way, but anything is possible through reflection.
http://en.wikipedia.org/wiki/Reflection_(computer_programming)

Simply put C can do this by running two (or more) programs that constantly modify and recompile one another. Thus anything that is possible at write-time is possible at run-time by utilizing this technique. Efficiency is another question.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List