www.digitalmars.com         C & C++   DMDScript  

DMDScript - bindings to SDL or SFML

reply Brad Cantrell <fraksworld hotmail.com> writes:
hello Walter and everyone, Im a big fan of Javascript as a language and Ive
been quite frustrated that all the Javascript compilers only seem to be
implemented in browsers and I can only use html as an I/O interface to the
language. Bartosz Milewski informed me about your compiler, I quite like it
and I think it could become popular for general use scripting, like how
Python, Ruby and Lua are for everyday use.

Id like to make a request, Id like to use Javascript to do simple graphics
programming with a library like SDL or SFML. I think you could popularize your
compiler and the Javascript language in general if you could create bindings
for these libraries. And since DMDScript is embeddable compiler, perhaps you
could create C++ files that register Javascript functions to your compiler.

Javascript is a fun and powerful language that really needs to break out of
its web programming confines.

thanks
Jun 21 2011
parent reply "Akakima" <akakima33 gmail.com> writes:
"Brad Cantrell" <fraksworld hotmail.com> a écrit dans le message de news: 
itrr64$2skl$1 digitalmars.com...
 hello Walter and everyone, Im a big fan of Javascript as a language and 
 Ive
 been quite frustrated that all the Javascript compilers only seem to be
 implemented in browsers and I can only use html as an I/O interface to the
 language.

This is something i was looking for too. I found at least 3 implementations that can be used (standalone) from the command line. 1. Spidermonkey engine (Original, developped by Mozilla) http://en.wikipedia.org/wiki/SpiderMonkey_%28JavaScript_engine%29 https://developer.mozilla.org/en/SpiderMonkey 2. The JSDB Project http://www.jsdb.org/ 3. The JSLIBS Project (has an SDL Interface) http://code.google.com/p/jslibs/ The last two, are based on SpiderMonkey. Latest SpiderMonkey stable release (1.8.5) implements ECMA 262 (Version 5). Has a JIT compiler. Of course, that would be great if DMD Script does all of this. But that would be a lot of work. But then, it might be also a lot of fun.
Jun 22 2011
parent Brad Cantrell <fraksworld hotmail.com> writes:
thanks a lot for those links Akakima, jslibs looks like they will give me a
good start
Jun 22 2011