Hacker News new | past | comments | ask | show | jobs | submit login
Replacing GNU assembler with Factor code (factor-language.blogspot.com)
38 points by fogus on Jan 26, 2010 | hide | past | favorite | 5 comments



What are the advantages/differences of using Factor compared to Forth?


From the FACTOR's FAQ: "Forth is untyped, not garbage collected, and close to the machine. For flow control, Forth code tends to use immediate words. Variables and arrays tend to be global, and programs aren't usually written in a functional manner. Factor is very different from this. It is dynamically typed, offering a high degree of reflection. Unreferenced objects are garbage collected with a generational garbage collector. Factor code is a little bit more distant from the machine, though the C FFI allows using words like malloc and mmap. For flow control, Factor generally uses quotations, allowing flexible higher order functions; parsing words are used mostly for definitions and data literals. Variables are dynamically or statically scoped, and arrays are just objects which don't need to be treated specially"


I'd say factor is to forth what clojure is to scheme: a modernized version (with a larger footprint).


Factor has very little in common with Forth, besides having a stack based concatenative syntax based off Forths. It has often been said within the Factor community that Factor has much much more in common with Lisp than it does with Forth.


Since almost every dynamic language is at one time or the other compared to lisp or praised as lisp + syntax + better + ..., I don't think the view of the Factor community is important.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: