How do I address individual elements inside an object

2020-12-17 Thread ToddAndMargo via perl6-users
Hi All, class Fruit { has Str $.location; has UInt $.apples; has UInt $.oranges; has UInt $.bananas; } my $FruitStand = Fruit.new( location => "Cucamonga", apples => 400, oranges => 200,

Re: classes and objects questions

2020-12-17 Thread ToddAndMargo via perl6-users
On 12/14/20 2:33 PM, ToddAndMargo via perl6-users wrote: Hi All, https://docs.raku.org/language/classtut "A tutorial about creating and using classes in Raku" So far so good. "Raku has a rich built-in syntax for defining and using classes." U. Forgot something

Re: Missing NullPointerException

2020-12-17 Thread Ralph Mellor
On Wed, Dec 16, 2020 at 5:10 AM Konrad Bucheli ... wrote: > there is surely a way to make sure that my Nil > explodes in my code. Is there a `use FailingNil`? I'd +1 a `use fatal :Nil;`. In the meantime, this appears to work: ``` engine.?Raptor::start ``` Might be a bug because an