Closed fallen-icarus closed 2 months ago
Oof... That's bad. Seems like this broke somewhere between v1.0.24 and v1.0.25. I'll do a quick git bisect to identify the issue. And seems like we have a hole in our test coverage.
Thanks for reporting @fallen-icarus.
The regression has been introduced in: ed9f5c6ef73b86b128adf81b8e1babe6ee1a3821
Probably in the PartialEq instance:
name == name2
&& module == module2
&& public == public2
&& args.iter().zip(args2).all(|(left, right)| left == right)
The zip
here is likely throwing all exceeding arguments between two sets. So it's only validating arguments up to the shortest length. In your example, there's (Int, Int)
being checked against (Int, Int, Bool)
, so it passes 🤦.
What Git revision are you using?
aiken v1.0.26-alpha+unknown
Describe what the problem is?
The following code typechecks, but it shouldn't.
The inner
foo
function is supposed to return(Int,Int,Bool)
when used withlist.foldl
, but in the above code, it returns(Int,Int)
.aiken check
just gives a warning thathas_proper_beacons
is unused. If I change it to return(offer_quantity, ada_quantity, has_proper_beacons)
,aiken check
successfully typechecks again, but this time without the warning.What should be the expected behavior?
The above code could should not typecheck.