I think that would be a great project for someone to take on. Just find & replace terms with other terms, and then send it through a compiler. It would basically be an optimizer / source hider.
The only real problem with this is that practically the entire program would just be B_CALLs if you want it to behave exactly like the input TI-BASIC program, which would not only increase the binary size by a large factor, but would see a very marginal gain in speed.
Kaslai wrote:
The only real problem with this is that practically the entire program would just be B_CALLs if you want it to behave exactly like the input TI-BASIC program, which would not only increase the binary size by a large factor, but would see a very marginal gain in speed.
I wouldn't even be surprised if you saw a reduction in speed, actually. There have been several projects in the community that attempt to do more in-depth conversion into a more optimized ASM form, but none are particularly complete or successful.
You'd be much better off if you just wrote a custom parser that handled BASIC tokens and wrote like BASIC, but was handled a lot more sanely than BASIC. It wouldn't operate exactly like BASIC, but it would afford you immense amounts of power. In fact, there are quite a few projects that do just this...
Kaslai wrote:
You'd be much better off if you just wrote a custom parser that handled BASIC tokens and wrote like BASIC, but was handled a lot more sanely than BASIC. It wouldn't operate exactly like BASIC, but it would afford you immense amounts of power. In fact, there are quite a few projects that do just this...
Indeed, and one such project is Grammar, which has a subforum on this very forum. KermMartian wrote:
Indeed, and one such project is Grammar, which has a subforum on this very forum.
You misspelled Grammer
But yeah, techboy6601 Axe and Grammer are good examples of what you want. You just need to keep in mind that even if their syntaxes are similar to TI-Basic, it is not TI-Basic.
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.
» Go to Registration page
» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Advertisement