On Friday, June 12, 2015 at 5:15:54 AM UTC+10, David Gold wrote: > > I want the following function > > function t_or_void{T}(::Type{Union(T, Void)}) > return T > end > > to work like this: > > julia> t_or_void(Union(Int, Void)) > Int64 > > Works like this on Julia 3.8, seems to be a regression?
> But in reality, it does this: > > julia> t_or_void(Union(Int, Void)) > UnionType > > Is there a way to make this work, or a way to extract T from Union(T, > Void)? The 'Void' isn't special -- it could be any determinate type. > > Thanks, > D >