Re: static types, checking, conversions

2008-04-17 Thread Larry Wall
On Thu, Apr 17, 2008 at 09:24:47AM +0200, TSa wrote: > HaloO, > > Larry Wall wrote: >> On Wed, Apr 16, 2008 at 04:29:23PM +, [EMAIL PROTECTED] wrote: >> : my Dog $spot = .new(); >> : : to >> : : my $Spot = Dog.new(); >> : : when you remove the declaration. >> >> You'd also break multiple dispat

Re: static types, checking, conversions

2008-04-17 Thread TSa
HaloO, [EMAIL PROTECTED] wrote: You should look at Common Lisp. it's definition of "optional typing" > is that if you take a correct program and remove all the type > declarations, then it still works correctly, although it may be > significantly less efficient. Larry and i have discussed this

Re: static types, checking, conversions

2008-04-17 Thread TSa
HaloO, Mark J. Reed wrote: Type checking in both js2/ecma4 and p6 is not merely documentation. It is enforced, but only if present. This is a tricky thing to achieve, which is why I suggested reading the js stuff to see how they went about it. I like the 'like' operator that does a structural

Re: static types, checking, conversions

2008-04-17 Thread TSa
HaloO, Larry Wall wrote: On Wed, Apr 16, 2008 at 04:29:23PM +, [EMAIL PROTECTED] wrote: : my Dog $spot = .new(); : : to : : my $Spot = Dog.new(); : : when you remove the declaration. You'd also break multiple dispatch rather badly... Sorry, why that? Isn't the dispatch on the dynamic

Re: static types, checking, conversions

2008-04-16 Thread Larry Wall
On Wed, Apr 16, 2008 at 04:29:23PM +, [EMAIL PROTECTED] wrote: : You should look at Common Lisp. it's definition of "optional typing" is that if you take a correct program and remove all the type declarations, then it still works correctly, although it may be significantly less efficient. L

Re: static types, checking, conversions

2008-04-16 Thread mark . a . biggar
You should look at Common Lisp. it's definition of "optional typing" is that if you take a correct program and remove all the type declarations, then it still works correctly, although it may be significantly less efficient. Larry and i have discussed this and that was his goai in Perl. Now P

Re: static types, checking, conversions

2008-04-16 Thread Mark J. Reed
Type checking in both js2/ecma4 and p6 is not merely documentation. It is enforced, but only if present. This is a tricky thing to achieve, which is why I suggested reading the js stuff to see how they went about it. On 4/16/08, Brandon S. Allbery KF8NH <[EMAIL PROTECTED]> wrote: > > On Apr 16,

Re: static types, checking, conversions

2008-04-16 Thread Brandon S. Allbery KF8NH
On Apr 16, 2008, at 3:44 , TSa wrote: I found two dissertations and a couple of papers about typing JavaScript. The quintessential is that optional typing is defined as having *no* impact on the dynamic behavior of the program. In that respect type annotations are like comments. I doubt that thi

Re: static types, checking, conversions

2008-04-16 Thread John M. Dlugosz
TSa Thomas.Sandlass-at-barco.com |Perl 6| wrote: I found two dissertations and a couple of papers about typing JavaScript. The quintessential is that optional typing is defined as having *no* impact on the dynamic behavior of the program. In that respect type annotations are like comments. I do

Re: static types, checking, conversions

2008-04-16 Thread John M. Dlugosz
Thom Boyer thom-at-boyers.org |Perl 6| wrote: Mark J. Reed wrote: It would behoove @Larry to examine the optional type constraints system proposed for Javascript:TNG (see link from firefox.com developers page). I therefore assume that they have done so, but others would benefit by doing likewis

Re: static types, checking, conversions

2008-04-16 Thread TSa
HaloO, Mark J. Reed wrote: It would behoove @Larry to examine the optional type constraints system proposed for Javascript:TNG (see link from firefox.com developers page). I therefore assume that they have done so, but others would benefit by doing likewise. :) Do I get that right: you imply

Re: static types, checking, conversions

2008-04-15 Thread Thom Boyer
Mark J. Reed wrote: It would behoove @Larry to examine the optional type constraints system proposed for Javascript:TNG (see link from firefox.com developers page). I therefore assume that they have done so, but others would benefit by doing likewise. :) Could you be a little more specific on

Re: static types, checking, conversions

2008-04-15 Thread Mark J. Reed
I apologize for the vagueness; I was away from browser when I sent that. Go to http://www.ecmascript.org for the nitty gritty on ECMAScript 4th Edition, a.k.a. "JavaScript 2", which is what I was talking about. White papers, specs, reference interpreter. The link from the Firefox developers page

Re: static types, checking, conversions

2008-04-15 Thread Mark J. Reed
It would behoove @Larry to examine the optional type constraints system proposed for Javascript:TNG (see link from firefox.com developers page). I therefore assume that they have done so, but others would benefit by doing likewise. :) On 4/15/08, TSa <[EMAIL PROTECTED]> wrote: > HaloO, > > John

Re: static types, checking, conversions

2008-04-15 Thread TSa
HaloO, John M. Dlugosz wrote: This needs to be fleshed out. Decisions need to be made. > Anyone want to discuss it with me? I want to. But give me time. Meanwhile you could read e.g. . This deals with F-bounded polymorphism in a tutorial st

static types, checking, conversions

2008-04-14 Thread John M. Dlugosz
I posted my thoughts as a sort of white paper here: http://www.dlugosz.com/files/static-type.pdf This needs to be fleshed out. Decisions need to be made. Anyone want to discuss it with me? --John