in reply to Re: Factory Pattern in Perl6
in thread Factory Pattern in Perl6
Thanks for your reply. I had to set this project aside for a little while, but I was able to return to it tonight and whittle down the actual problem.
After some playing around, the reason turned out to be the specific object being tested having a BUILDALL. Commenting out the BUILDALL method allowed the object to be constructed in the right class.
To narrow it down from there, the BUILDALL started by calling callsame, as discussed in https://doc.perl6.org/language/objects. Changing that to nextsame (as shown in https://doc.perl6.org/language/traps) allowed the object to be constructed as expected.
"There is no shame in being self-taught, only in not trying to learn in the first place." -- Atrus, Myst: The Book of D'ni.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Factory Pattern in Perl6
by raiph (Deacon) on May 18, 2016 at 05:17 UTC | |
by hardburn (Abbot) on May 18, 2016 at 22:00 UTC | |
by raiph (Deacon) on May 19, 2016 at 21:14 UTC | |
by hardburn (Abbot) on May 20, 2016 at 20:31 UTC | |
by raiph (Deacon) on May 22, 2016 at 04:40 UTC | |
|