Misleading error message in Primes

On my system

N = Int64(2)^30
primes(N)

works fine. However

N = BigInt(2)^30
primes(N)

throws

LoadError: primes(1073741824,) has been moved to the package Primes.jl.
Run Pkg.add("Primes") to install Primes on Julia v0.5-

This should probably be filed as a bug to the Primes.jl package: https://github.com/JuliaMath/Primes.jl

The functions should be accepting Integer, but they’re currently specified for Int.

2 Likes