Nick Ing-Simmons writes: : >You really have to talk about overloading boolean context : >in general. : : Only if you are going to execute the result in the normal perl realm. : Consider using the perl parser to build a parse tree - e.g. one to : read perl5 and write perl 6. This works for all expressions except : &&, || and ?: because perl5 cannot overload those - so : : $c = ($a && &b) ? $d : $e; : : calls the bool-ness of $a and in the defered execution mode of a translator : it wants to return not true/false but "it depends on what $a is at run-time". : It cannot do that and is not passed $b so cannot return I think using overloading to write a parser is going to be a relic of Perl 5's limitations, not Perl 6's. Larry
- Re: Tying & Overloading Dan Sugalski
- Re: Tying & Overloading Jarkko Hietaniemi
- Re: Tying & Overloading Filipe Brandenburger
- Re: Tying & Overloading Dan Sugalski
- Re: Tying & Overloading Filipe Brandenburger
- Re: Tying & Overloading Dan Sugalski
- Re: Tying & Overloading Filipe Brandenburger
- Re: Tying & Overloading Dan Sugalski
- Re: Tying & Overloading Larry Wall
- Re: Tying & Overloading Nick Ing-Simmons
- Re: Tying & Overloading Larry Wall
- Re: Tying & Overloading Nick Ing-Simmons
- Re: Tying & Overloading Larry Wall
- Re: Tying & Overloading Edward Peschko
- Re: Tying & Overloading Simon Cozens
- Re: Tying & Overloading Davíð Helgason
- Re: Tying & Overloading Simon Cozens
- Re: Tying & Overloading Simon Cozens
- Re: Tying & Overloading Graham Barr
- Re: Tying & Overloading H . Merijn Brand
- Re: Tying & Overloading Graham Barr