On Sun, 13 Mar 2005 18:03:20 -0800, Larry Wall <[EMAIL PROTECTED]> wrote: > On Sun, Mar 13, 2005 at 01:15:52AM -0600, Rod Adams wrote: > > : =item multi sub cos (?Num) returns Num > : > : =item multi method Num::cos () returns Num > > It would be nice if we could just say the first implies the second. > I guess what that effectively means is that even if you take the > default, it's only the value that's optional, not the type. And, > in fact, you'd have to put the ? on the variable, not on the type, > so you might write those > > =item multi sub cos (Num ?$n = $CALLER::_) returns Num > > instead. Shall we settle on $x, $y, $z for standard Num args? In which > case that becomes > > =item multi sub cos (Num ?$x = $CALLER::_) returns Num
For documentary purposes, can we make that $radians? multi sub cos (Num +$degrees) returns Num { return cos :radians($degrees * PI / 180); } my Num $x = cos :degrees(270); Ashley Winters