compilation - Difference between a constant and variable member in compiled or interpreted code -
for while have been little confused role of constant members within language, such java or c. understand @ source code level, prevent critical members beingness mutated , changed, when compiled or interpreted, there difference between them , variable members @ or pointers memory addresses?
i thought perhaps compiler/interpreter has implement special allow variable mutable, wouldn't have when handling constant fellow member (perhaps making execution faster or making utilize less memory?), true or wrong tree?
the const variable , variable not stored in same place 1 time code executed. constant values go in flash memory program. variables go in flash copied in ram modified programme runs. making variable const makes computer save time , space not pushing in ram. when need modify it, force ram anyway, of time const variables not modified. in add-on software fact might want prevent code modify value mistake.
variables compilation constants language-design interpretation
No comments:
Post a Comment