Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save andreypopp/8d31a8cb7c02935935c26f6503cac024 to your computer and use it in GitHub Desktop.

Select an option

Save andreypopp/8d31a8cb7c02935935c26f6503cac024 to your computer and use it in GitHub Desktop.
diff --git a/K.jl/src/K.jl b/K.jl/src/K.jl
index d07490f..4171edc 100644
--- a/K.jl/src/K.jl
+++ b/K.jl/src/K.jl
@@ -1267,6 +1267,7 @@ arity(::Encode)::Arity = 1:1
begin
len = x + 1
T = Base.promote_op(o.f, eltype(y))
+ if T == Union{}; T = Any end
r = Vector{T}(undef, len)
@inbounds r[1] = y
i = 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment