I’m trying to figure out a way to eval c sharp code like you can do with the javascript code. Has anyone done this before and could point me in the right direction?
there is no counterpart and if your target in which relation you ask this is still iOS as on the other thread, then the answer is: it wouldn’t work anyway, as eval doesn’t do either
Yeah, thanks for the reply. I figured out that the overly secure iOS prevents any kind of code injection. How sad.
It’s not about security, it’s that iOS uses AOT compilation, so anything related to JIT is impossible.
–Eric
Thats the real reason but even if it would work, it would not be accepted by apple to do so as it would generate code that code access stuff outside of what the previously compiled code does and thats against the TOS
Theoretically true, but Apple seems selective about enforcing that (like emulated code in various games, such as most of Sega’s).
–Eric
No its not selective at all, anymore at least.
The reason apple fought that for a long time was the same they fought other absurd fights: Their share in the cash and license infridgement risk (C64 emulator had the serious potential for this - which would get apple sued primarily not the dev as apple has the 300B worth, not some hacky backdoor kiddo group)!
Emulators don’t inject new code for example neither do Shiva - SiO2 - GameSalad games, yet all of them have scripting in.
Their real code is always fixed though, script / ROMs can only use what was there at approval time already.
Part of why this got possible is also that apple included the “generate debug symbols” requirement for your send ins with the cut of the web upload, that gives them far straighter and more extensive access during approval to see what you use in your code, even when not called at the time of approval.