in reply to Re^7: Assignable Subroutines
in thread Assignable Subroutines

I think you're suffering from tunnel vision. TimToady said that the typing mechanisms in Perl6 would help alleviate the validation issues you're running into. He didn't say that those mechanisms would be your only validation prospect. You should know by now that Perl doesn't say anything but TMTOWTDI.

Now, if you wanted to use the typing mechanisms, you're more than welcome to it. And, there will be sufficient support that you can define your types in one place and use them everywhere.

But, if you wanted to use, say, pre- and post-execution subroutines or Params::Validate or any other scheme ... go right ahead. If you wanted to use a mix of them ... go right ahead.

The point is that typing exists and is expected to alleviate some of the validation burden. It's not going to be the only possibility. TMTOWTDI is where languages like Pascal fall down. It's not the typing system.

Being right, does not endow the right to be rude; politeness costs nothing.
Being unknowing, is not the same as being stupid.
Expressing a contrary opinion, whether to the individual or the group, is more often a sign of deeper thought than of cantankerous belligerence.
Do not mistake your goals as the only goals; your opinion as the only opinion; your confidence as correctness. Saying you know better is not the same as explaining you know better.

Replies are listed 'Best First'.
Re^9: Assignable Subroutines
by Aristotle (Chancellor) on Jan 26, 2005 at 17:53 UTC

    TMTOWTDI is where languages like Pascal fall down. It's not the typing system.

    Actually the type system is why vanilla Pascal is useless while C isn't. Pascal includes the length of an array in the type, which makes it impossible to pass a STRING[40] to a function with a signature expecting a STRING[100].

    Makeshifts last the longest.

Re^9: Assignable Subroutines
by BrowserUk (Patriarch) on Jan 26, 2005 at 17:05 UTC

    Updated: to correct my misreading of who I was responding to. dragonchild's sudden interjection into what had been a two person thread caught me out. I apologise to dragonchild for my mis-attributions.

    I am not suffering from tunnel vision.

    You Someone else brought up the typing system--not I.

    I simply explained why typing is no alternative to validation.

    You are completly ignoring all the reasons I have outlined why the tie mechanism cannot be used to perform validation.

    But, if you wanted to use, say, pre- and post-execution subroutines or Params::Validate or any other scheme...

    When? How? Show me an example?

    I have, in answer to your previous assertions, shown how the mechanism described for validation of the value assigned won't work. Now you throw this in as if it answers something? It doesn't!

    All of the problems outlined still remain unanswered and this throwaway line doesn't even pretend to address them.


    Examine what is said, not who speaks.
    Silence betokens consent.
    Love the truth but pardon error.