Opportunity missed by Python ?

Chris Rebert clp2 at rebertia.com
Thu Oct 13 07:12:14 EDT 2011


On Thu, Oct 13, 2011 at 3:07 AM, Chris Angelico <rosuav at gmail.com> wrote:
> On Thu, Oct 13, 2011 at 8:45 PM, candide <candide at free.invalid> wrote:
>> Dart is the very new language created by Google to replace Javascript.
>> So Python was not able to do the job? Or may be they don't know about Python
>> at Google ;) ?
>>
>
> Python, as I found out to my detriment, is practically impossible to
> sandbox effectively. Any language that hopes to gain full traction in
> a browser-based environment MUST be secure against scripts gaining too
> much control over the browser chrome.
>
> Also, Dart is looking to support (optional) strict typing, which
> Python doesn't do. That's a fairly major performance enhancement.

Actually, they can't use it as much more than an optimization hint,
per their own spec (see Sec 13.1 of the draft):

"Static type annotations are used during static checking and when
running programs in checked mode. They have no effect whatsoever in
production mode.
[...]
A Dart implementation must provide a static checker that detects and
reports exactly those situations this specification identifies as
static warnings. However:
• Running the static checker on a program P is not required for
compiling and running P.
• Running the static checker on a program P must not prevent
successful compilation of P nor may it prevent the execution of P,
regardless of whether any static warnings occur."

Cheers,
Chris
--
http://rebertia.com



More information about the Python-list mailing list