Skip Menu |
Report information
Id: 72580
Status: resolved
Priority: 0/
Queue: perl6

Owner: nine [at] detonation.org
Requestors: masak <cmasak [at] gmail.com>
Cc:
AdminCc:

Severity: (no value)
Tag: Bug
Platform: (no value)
Patch Status: (no value)
VM: (no value)



Subject: [BUG] Bool enum values don't smartmatch against Int in Rakudo
Date: Sat, 6 Feb 2010 17:21:41 +0100
To: rakudobug [...] perl.org
From: Carl Mäsak <cmasak [...] gmail.com>
Download (untitled) / with headers
text/plain 331b
<TimToady> rakudo: enum X <a b c>; say a ~~ Int; say True ~~ Int # buglet <p6eval> rakudo 1d4928: OUTPUT«1␤0␤» <jnthn> Aye. <jnthn> Quick! Masak! <jnthn> :-) <masak> what? what? :) * masak submits TimToady++'s rakudobuglet <masak> oh, I see now! True is (supposed to be) an enum too. <masak> an enum value. <TimToady> yeah
RT-Send-CC: perl6-compiler [...] perl.org
Download (untitled) / with headers
text/plain 633b
On Sat Feb 06 08:22:31 2010, masak wrote: Show quoted text
> <TimToady> rakudo: enum X <a b c>; say a ~~ Int; say True ~~ Int # buglet > <p6eval> rakudo 1d4928: OUTPUT«1␤0␤» > <jnthn> Aye. > <jnthn> Quick! Masak! > <jnthn> :-) > <masak> what? what? :) > * masak submits TimToady++'s rakudobuglet > <masak> oh, I see now! True is (supposed to be) an enum too. > <masak> an enum value. > <TimToady> yeah
The output has changed to: 01:21 <[Coke]> rakudo: enum X <a b c>; say a ~~ Int; say True ~~ Int # buglet 01:21 <p6eval> rakudo 549d2a: OUTPUT«Bool::True␤Bool::False␤» but the second value should be true too. -- Will "Coke" Coleda
2012.10 - still broken $ perl6 -e 'enum X <a b c>; say a ~~ Int; say True ~~ Int' True False
RT-Send-CC: perl6-compiler [...] perl.org
Download (untitled) / with headers
text/plain 341b
On Thu Nov 15 05:08:56 2012, bbkr wrote: Show quoted text
> 2012.10 - still broken > > $ perl6 -e 'enum X <a b c>; say a ~~ Int; say True ~~ Int' > True > False
Fixed now; nine++ did the majority of the hard work, and I cleaned up the last few issues just now and merged the work and spectest updates, including coverage added in S02-types/bool.t. /jnthn


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

For issues related to this RT instance (aka "perlbug"), please contact perlbug-admin at perl.org