Skip to content

Commit

Permalink
Remove two dummy parameters from (Fat)Rat coercer
Browse files Browse the repository at this point in the history
These appear to have been added with c33f355 in 2011,
and basically rendered useless a little later in 2011.  Removal is
spectest clean, so I see no reason to keep them.
  • Loading branch information
lizmat committed Jan 13, 2022
1 parent 21829c3 commit 6c76560
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core.c/Rat.pm6
Expand Up @@ -34,10 +34,10 @@ my class Rat is Cool does Rational[Int, Int] {
my constant UINT64_UPPER = nqp::pow_I(2, 64, Num, Int);

my class FatRat is Cool does Rational[Int, Int] {
method FatRat(FatRat:D: Real $? --> FatRat) {
method FatRat(FatRat:D: --> FatRat) {
self
}
method Rat(FatRat:D: Real $? --> Rat:D) {
method Rat(FatRat:D: --> Rat:D) {
$!denominator < UINT64_UPPER
?? Rat.new($!numerator, $!denominator)
!! Failure.new("Cannot convert from FatRat to Rat because denominator is too big")
Expand Down

0 comments on commit 6c76560

Please sign in to comment.