You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
julia> Supposition.@checkfunctioncheckassociativeinstance(a::Data.Floats(),b::Data.Floats(),c::Data.Floats())
(a + b) + c == a + (b + c)
end
ERROR: LoadError: ArgumentError: An argument doesn't have a generator set!
in expression starting at REPL[13]:1
How could this be communicated better?
It says "An argument doesn't have a generator set!" but
I don't know what a generator set is
Why is it yelling at me (with a !)
Julia Version
julia>versioninfo()
Julia Version 1.10.0
Commit 3120989f39b (2023-12-25 18:01 UTC)
Build Info:
Official https://julialang.org/ release
Platform Info:
OS: Linux (x86_64-linux-gnu)
CPU: 24 × AMD Ryzen 9 3900XT 12-Core Processor
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-15.0.7 (ORCJIT, znver2)
Threads: 17 on 24 virtual cores
Environment:
JULIA_NUM_THREADS = 12
Package Environment
(@main) pkg> st Supposition
Status `~/.julia/environments/main/Project.toml`
[5a0628fe] Supposition v0.3.1
The text was updated successfully, but these errors were encountered:
The syntax is a=Data.Floats(), not a::Data.Floats(); i.e. you're assigning/setting a to use elements from Data.Floats(). It's not a type assertion, because Data.Floats() is not a type, and you can reuse properties defined in this way with other generators that produce other element types.
Would "An argument doesn't have a generator assigned!" be better? I'm using exclamation marks here to indicate a critical problem, not to yell (yelling would be "AN ARGUMENT DOESN'T HAVE A GENERATOR ASSIGNED!").
Ideally it would recognize this :: vs = syntax mistake specially and tell me. In #2 I apparently thought of :: too so I figure this won't be the last time somebody makes this mistake.
The next best thing might be
argument a has no Possibility assigned. Try a=Data.Just(3) or similar.
(Maybe giving an example is pushing it too far.) But using the word Possibility instead of "generator" seems good, since that's what's missing.
As for the !, we're in an error message so I already know it's a failure: I prefer a calmer experience - just the facts.
Uh oh!
There was an error while loading. Please reload this page.
What happened?
How could this be communicated better?
It says "An argument doesn't have a generator set!" but
!
)Julia Version
Package Environment
The text was updated successfully, but these errors were encountered: