Possible New Purpose for D?
Ryan
dlang at zipxap.com
Fri Jan 17 07:53:03 PST 2014
The purpose of this post is to gage interest. I honestly have no
idea how many people would see a need for this. I am open to any
and all comments, but please begin your response with a 1 to 10
number that indicates value/interest.
Summary:
We need a client-side embedded scripting language for
applications written in the new world of cloud computing and
heterogeneous client devices.
To prevent mischievous delinquent from being able to sabotage the
host application or create cross-scripting attacks, this
scripting language must not provide access to the underlying
browser, through either JavaScript (eval!!) or the DOM. It
would, however, need to allow for controlled extensibility
through JavaScript, so that application developers could make
their web application client-side scriptable.
Another benefit is that classes could be compiled down to
bytecode and sent to the client on demand using ajax.
A third benefit of this is that by maintaining a purely D
language environment, it opens the possibility to easily porting
standard libraries, including things like DWT, and using them in
the browser. Since HTML5 provides the ability to offline
applications, etc, download size becomes less of a concern
(although always a concern), since subsequent visits to the
application would utilize a locally cached copy.
I wrote a VM and compiler a few years ago because I was playing
with my own language. I might consider porting it to JavaScript
and then implement a D compiler if people thought it would open
up new possibilities.
As an aside, I did a quick search to see if other VMs were
available written in JavaScript. There are many, including a
full Linux VM!!! Here are two Python VMs I found:
http://www.skulpt.org/
http://www.brython.info/
The point is that I might be able to find much of the
infrastructure from other open-source projects, although they all
seem to want to provide JavaScript/DOM access.
More information about the Digitalmars-d
mailing list