Arc Forumnew | comments | leaders | submitlogin
An idea for a new language: "Dynamic Forth" (github.com)
3 points by ylando 4665 days ago | 5 comments


1 point by akkartik 4665 days ago | link

What scheme are you running test.scm with? On racket:

  $ racket -f test.scm
  test.scm:20:8: if: bad syntax (must have an "else" expression) in: (if (and (not (null? p)) (> (car p) *global-stack-depth*)) (begin (set-car! p *global-stack-depth*) (loop (cdr p))))

-----

1 point by ylando 4665 days ago | link

I have an idea for a programming language that can be use like the normal mode in vim or as a rpn calculator instead of dc.

-----

1 point by akkartik 4665 days ago | link

Can you elaborate? The readme didn't mention normal mode in vim.

-----

2 points by ylando 4665 days ago | link

Sorry I fix a namespace problem and now it works in gambit scheme and in r5rs language of racket. About normal mode in vim: I meant that it can be used as a real time scripting language. Suppose that you write your own program, It will be easy for the user to press ESC write dynamic forth expression and press enter. If he will do the same with arc, he will have to worry about parentheses. He will also have trouble using the result of the last calculation.

-----

1 point by akkartik 4664 days ago | link

Ah thanks. In racket I need to add this line to the top of the generated file:

  #lang r5rs
(There doesn't seem any commandline flag to specify the language.)

-----