Skip to content

=== nothing is not == nothing with --code-coverage=user #32579

Closed
@tkf

Description

@tkf

I just have a very strange bug that cannot be reproduced locally and replacing === nothing with == nothing (as below) fixes this bug.

diff --git a/examples/primes.jl b/examples/primes.jl
index 7dac9d2f..0f194e7f 100644
--- a/examples/primes.jl
+++ b/examples/primes.jl
@@ -11,7 +11,7 @@ using Transducers

 function sieve(xf, x)
     @info "sieve(xf, x=$x)"
-    if (@show mapfoldl(xf, right, (x,), init=nothing)) === nothing
+    if (@show mapfoldl(xf, right, (x,), init=nothing)) == nothing
         @info "$x is NOT prime"
         nothing, xf
     else

See: https://travis-ci.com/tkf/Transducers.jl/builds/119090143 (Ref JuliaFolds/Transducers.jl#17)

Maybe it's relevant to #32135?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIndicates an unexpected problem or unintended behaviorcompiler:optimizerOptimization passes (mostly in base/compiler/ssair/)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions