D for projects similar to Forth Interpreters?

Nicholas Wilson iamthewilsonator at hotmail.com
Sat Apr 6 09:45:58 UTC 2024


On Saturday, 6 April 2024 at 08:43:36 UTC, Dmitry Ponyatov wrote:
>> In this case what would be the pros and cons if any of D 
>> compared with C or asm?
>
> If you're not chasing for speed, using objects, types stack and 
> `Object*[string] W` vocabulary and symbolic string-addressed 
> memory looks more fun than classical raw machine numbers and 
> bytes.
>
> I did this with Python version earlier (and tried C++ also), so 
> having
> `[ <int:123> <point:45 at 67> <window:hello> ]` on data stack 
> looks much handy than dumb integers.
>
> Interpreter tracks all typed operations, and parser allows you 
> to use inline arithmetics and pushes executable ASTs on top of 
> stack.
>
> So, D has its own gc, and you don't need to bother about 
> refrecounting and manual memory management across all the code 
> as you must do it in C++.

Why did you reply to this thread? it is 15 years old.


More information about the Digitalmars-d mailing list