Jonathan Scott Duff wrote: > > If we had a context coercion operator that was the opposite of want() > we could do something like this: > > print context '*STRING', $val; # long-hand for print $val > print context '*SCALAR', $val; # we're not in a string context > print context 'MyClass', $val; # we're not in a string context We already have scalar(). We should also have string(), void(), etc. for the "intrinsic" contexts. -- John Porter
- RFC 48 (v2) Objects should have builtin stringifying Perl6 RFC Librarian
- Re: RFC 48 (v2) Objects should have builtin strin... Michael Mathews
- Re: RFC 48 (v2) Objects should have builtin s... Nathan Wiger
- Re: RFC 48 (v2) Objects should have builtin strin... Dan Sugalski
- Re: RFC 48 (v2) Objects should have builtin s... Nathan Torkington
- Re: RFC 48 (v2) Objects should have builtin strin... Michael Fowler
- Re: RFC 48 (v2) Objects should have builtin s... Jonathan Scott Duff
- Re: RFC 48 (v2) Objects should have built... John Porter
- Re: RFC 48 (v2) Objects should have b... Jonathan Scott Duff
- Re: RFC 48 (v2) Objects should h... John Porter
- Re: RFC 48 (v2) Objects should have builtin s... Nathan Wiger
- Re: RFC 48 (v2) Objects should have built... Dan Sugalski
- Re: RFC 48 (v2) Objects should have built... Michael Fowler
- Re: RFC 48 (v2) Objects should have b... John Porter
- Re: RFC 48 (v2) Objects should h... Dan Sugalski
- Re: RFC 48 (v2) Objects should h... Hildo Biersma
- Re: RFC 48 (v2) Objects shou... John Porter
- Re: RFC 48 (v2) Objects should h... Piers Cawley