- Joined
- Sep 21, 2022
- Messages
- 226
- Reaction score
- 36
I recently had to change operating system, and the new version of my prefered language has got some serious problems that make running my programs impossible.
I have a very large library of routines that I reuse. The things they do are very esoteric. So they won't come standard with a new language.
So I've been thinking about what kind of programming style is good for porting a large library from one system to another.
In a perfect world I'd use only Turing machine programs (or some other kind of virtual machine). Porting would be writing one program (simulator) on the new system, and then just copy all my files over. Not very realistic.
I could code in a subset of my prefered language, using operators and concepts common to every programming language. Doable but I suspect it will look a lot like assembly, I'm seriously considering this one.
Another idea is to use functions for everything, even operators. Completely hide the system details from 99% of my code. Just change a few primitive functions when porting. I suspect this will run like a slug.
Or I could just say f*ck it, and go back to pen and paper. But I do rather like what loops can do.
I don't mind rewriting my library, but only once.
I have a very large library of routines that I reuse. The things they do are very esoteric. So they won't come standard with a new language.
So I've been thinking about what kind of programming style is good for porting a large library from one system to another.
In a perfect world I'd use only Turing machine programs (or some other kind of virtual machine). Porting would be writing one program (simulator) on the new system, and then just copy all my files over. Not very realistic.
I could code in a subset of my prefered language, using operators and concepts common to every programming language. Doable but I suspect it will look a lot like assembly, I'm seriously considering this one.
Another idea is to use functions for everything, even operators. Completely hide the system details from 99% of my code. Just change a few primitive functions when porting. I suspect this will run like a slug.
Or I could just say f*ck it, and go back to pen and paper. But I do rather like what loops can do.
I don't mind rewriting my library, but only once.