Javascript bytecode
Walter Bright
newshound2 at digitalmars.com
Fri Dec 21 02:46:32 PST 2012
On 12/21/2012 2:37 AM, Araq wrote:
> On Friday, 21 December 2012 at 10:30:21 UTC, Walter Bright wrote:
>> On 12/21/2012 2:13 AM, Max Samukha wrote:
>>> What Walter is wrong about is that bytecode is entirely pointless.
>>
>> I'll bite. What is its advantage over source code?
>
> Interpreting the AST directly: Requires recursion.
> Interpreting a (stack based) bytecode: Does not require recursion.
>
> That's what an AST to bytecode tranformation does; it eliminates the recursion.
> And that is far from being useless.
Sorry, I don't get this at all. Every bytecode scheme I've seen had a stack and
recursion.
Furthermore, that's not an argument that transmission of code (and importation
of modules) is better done as bytecode than source code.
More information about the Digitalmars-d
mailing list