Re: Danger! Type-checking & the translator

new topic     » goto parent     » topic index » view thread      » older message » newer message

On Mon, 27 Jan 2003 23:54:15 +0000, Andy Serpa <ac at onehorseshy.com> wrote:

>
>
>> According to the Translator docs:
>>
>> "User-defined types will not affect your speed. They are ignored by the
>> translator unless you also call them directly with normal function 
>> calls."
>>
> Ok, found it.  It is under the section about "speed" when it ought to be 
> mentioned promiently under a section about "why your code might not still 
> work".
>
>>
>> > It should say, "You can't use custom
>> > types in translated programs, period."
>>
>> Of course you can, but they are ignored
>> just as if you had said "without type_check".
>> Actually, they are not completely ignored.
>> The Translator can still pick up information from them,
>> such as whether your variable is a subset of integer, sequence etc.
>>
> Well, if you have to call them explicitly, then they become normal 
> functions.  Effectively, you can't use types as types.
>
>> It won't be in 2.4 though. My schedule has slipped too much already.
>> I'm still hoping for a release in 10 days (I added some new stuff).
>>
>
> Please, put it on the list for 2.5...
>
>
>
> TOPICA - Start your own email discussion group. FREE!
>
>

Agreed. The only advantage of types over normal functions is that they are 
called automatically. If the translator omits that, then why bother with 
them at all?

-- 

cheers,
Derek Parnell

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu