objective c - Can I modify a variable via it's name as a string? -


this question has answer here:

is there way me modify variable string containing it's name?

something this:

int example = 1; nsstring *foo = @"example"; foo.value++ 

at point, example equal 2.

you can't local variables that. can instance variables using kvc.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -