We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4d8548e commit 35382f4Copy full SHA for 35382f4
src/types.jl
@@ -298,7 +298,12 @@ function UnivariateFinite(
298
299
# `LittleDict`s preserve order of keys, which we need for rand():
300
_support = keys(prob_given_class) |> collect |> sort
301
-
+ isempty(_support) && throw(
302
+ ArgumentError(
303
+ "Cannot create `UnivariateFinite` and `UnivariateFininiteArray`"*
304
+ " objects with no classes/support."
305
+ )
306
307
# retrieve decoder and classes from first key:
308
class1 = first(_support)
309
parent_decoder = decoder(class1)
0 commit comments