Why does .new initialize?

2021-07-18 Thread Peter Scott

I'm curious as to why Rat.new initializes instead of leaving as undefined:

> $*RAKU
Raku (6.d)
> my Rat $p
(Rat)
> put $p
Use of uninitialized value $p of type Rat in string context.
Methods .^name, .raku, .gist, or .say can be used to stringify it to 
something meaningful.

  in block  at  line 1
> my $q = Rat.new
0
> put $q
0


Peter Scott


Re: searching for a blog

2021-07-18 Thread Marcel Timmerman

On 7/18/21 4:03 PM, Matthew Stuckwisch wrote:

I think it was Daniel Sockwell (codesections) that played around with it. See the blog 
entry at  and the associated 
Pod::Literate module at 
 .

There's also my Test::Inline (I know I posted about it somewhere but I don't believe 
it was on a blog) which can be found at 
, but it doesn't integrate POD6.

Matéu


Matéu, thank you for the links. It wasn't any of these but the last one had a 
link to reddit and at the start there was the link I remembered; 
https://www.codesections.com/blog/raku-unit-testing-with-conditional-compilation/.
 My brain mixed up also on the use of pod docs, instead it was about using DOC 
blocks.

Thanks again,
Marcel





On Jul 18, 2021, at 09:19, Marcel Timmerman  wrote:

Hi,

I am searching for a blog of someone who explained how to write testing code 
next to the programs code. I believe the testing code was written in pod 
documentation. I am interested in the way it was done but can't find the blog 
anymore.

Does anyone have a link to the blog for me?
Thanks,
Marcel




Re: searching for a blog

2021-07-18 Thread Matthew Stuckwisch
I think it was Daniel Sockwell (codesections) that played around with it. See 
the blog entry at  and the 
associated Pod::Literate module at 
 .

There's also my Test::Inline (I know I posted about it somewhere but I don't 
believe it was on a blog) which can be found at 
, but it doesn't integrate POD6.

Matéu


> On Jul 18, 2021, at 09:19, Marcel Timmerman  wrote:
> 
> Hi,
> 
> I am searching for a blog of someone who explained how to write testing code 
> next to the programs code. I believe the testing code was written in pod 
> documentation. I am interested in the way it was done but can't find the blog 
> anymore.
> 
> Does anyone have a link to the blog for me?
> Thanks,
> Marcel



searching for a blog

2021-07-18 Thread Marcel Timmerman

Hi,

I am searching for a blog of someone who explained how to write testing 
code next to the programs code. I believe the testing code was written 
in pod documentation. I am interested in the way it was done but can't 
find the blog anymore.


Does anyone have a link to the blog for me?
Thanks,
Marcel