سؤال

I'm planning on designing and implementing my own programming language. Is it a good idea to build my language in Java and run it off of the JVM or would my language be faster if I wrote it in C and ran the code off of my own virtual machine?

هل كانت مفيدة؟

المحلول

Maybe you can write your compiler in Java and let it compile to Java byte code. If you want to do this, you can have a look at the book "Compiler Construction" by Niklaus Wirth for the compiler part and use ASM(Java) to generate the bytecode. But you should think, wether you really want to build a compiler - it is not very easy.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top