Minor extension to cast syntax

Gregor Richards Richards at codu.org
Wed Oct 31 20:56:07 PDT 2007


Bruce Adams wrote:
> Gregor Richards Wrote:
> 
>> Bruce Adams wrote:
>>> Gregor Richards Wrote:
>>>
>>>> Gregor Richards wrote:
>>>>>> There is that idea in language design that if it can be done as a 
>>>>>> function it should be unless there is a good reason not to.
>>>>> In highly dynamic languages where performance isn't a primary objective, 
>>>>> yes. Dynamic arrays, anyone?
>>>>>
>>>> I should also mention, while I'm at it, that this can NOT be done as a 
>>>> function.
>>>>
>>>>   - Gregor Richards
>>> It could if your language was dynamic enough to support types as first class objects so that no meta syntax was required. :)
>>>
>> Yeah, but that's a matter of goals ... I love dynamic languages, my pet 
>> language is entirely prototype-based, so "types" are really just 
>> prototype objects, and are therefore passable like any other object. It 
>> makes things like generics really easy and intuitive, and of course 
>> casting is just one comparison away :)
>>
>> But D is a static language, and has different goals.
>>
>>   - Gregor Richards
> 
> Agreed but wouldn't it be nice to find a language with the best of both world? By the way, which is your pet language.
> 
> Regards,
> 
> Bruce.

A little language I call "Plof". http://www.codu.org/plof/

Plof2 is the current incarnation, which (as with Plof1) is giving way to 
Plof3 :P ... suffice to say that Plof isn't really a usable language 
yet, I mainly use it as an environment for playing with language design.

  - Gregor Richards



More information about the Digitalmars-d mailing list