5 ms·
I've tried. It's just hard, frankly. I'm just not that good a coder :(
by grondilu 9y ago
I've tried. It's just hard, frankly. I'm just not that good a coder :(
- Cyph0n 9y agoEhh I don't think so. I'm certain that you are a good coder. You just need to learn more about the techniques needed to implement a Perl to WASM compiler, and obviously, a ton of time. You can do it man.
- BenGoldberg 9y agoThe stuff which makes perl really awesome are the distributions on CPAN. Many (though not all) of these distributions contain XS, which is a type of glue between perl and C. Most of these XS distributions are there to link to some library -- Math::GMP, for example, lets perl code use the GNU gmp multi precision math library. Without some way to make use of distributions with XS parts, then a perl to $other_language_here transpiler is not going to be very interesting.
- Cyph0n 9y agoThat makes sense. Library compatibility is a tough issue to deal with. Scala.js faces the same issue when it comes to libraries that depend on the Java stdlib. I believe their goal is to port the entire stdlib, but I'm not sure tbh. It might just be an insurmountable problem.
- petre 9y agoActually quite few are XS and XS is painful/a terrible way to plug C code inside of the Perl interpreter's guts. For this reason Perl6 aims to rewrite most of the stuff in Perl6/NQP and use NativeCall to call on external libraries.
- dozzie 9y agoI know you're being encouraging, but I think you're underestimating the complexity of Perl parser. From what I remember, there were three subsystems that voted for each expression what programmer meant.
- Cyph0n 9y agoYou are right, I'm completely ignorant on the topic haha. Could you clarify what you mean by "vote"?
- tyingq 9y agoPerl has some syntax that can be ambiguous. To the point that some code can't be parsed without running it. See this for more on that: http://www.perlmonks.org/?node_id=663393 http://www.perlmonks.org/?node_id=663393