Changeset 22515 for t/spec/S12-methods/what.t
- Timestamp:
- 10/05/08 19:58:12 (3 months ago)
- Files:
-
- 1 modified
-
t/spec/S12-methods/what.t (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
t/spec/S12-methods/what.t
r21472 r22515 25 25 { 26 26 my $a = 3; 27 #?rakudo todo 'Int type should somehow conform to Num' 27 28 ok($a.WHAT ~~ Num, "an Int isa Num"); 28 29 ok($a.WHAT ~~ Object, "an Int isa Object"); … … 32 33 { 33 34 my $a = sub ($x) { 100 + $x }; 35 #?rakudo 2 todo 'correct types for subs and blocks' 34 36 ok($a.WHAT === Sub, "a sub's type is Sub"); 35 37 ok($a.WHAT ~~ Routine, "a sub isa Routine"); … … 45 47 my $o = Foo.new; 46 48 is($o."WHAT", 'Bar', '."WHAT" calls the method instead of the macro'); 49 #?rakudo todo '.WHAT not (easily overridable)' 47 50 is($o.WHAT, 'Foo', '.WHAT still works as intended'); 48 51 my $meth = "WHAT"; 52 #?rakudo skip 'indirect method calls' 49 53 is($o.$meth, 'Bar', '.$meth calls the method instead of the macro'); 50 54 }
