Hi everyone,
I was writing an Option Monad, and this is what i get from the following line:
m_join{T1<:Option,T2<:Option,T}(x::T1{T2{T}}) = get(None{T}(),x)
and structure of Option is as follows:
abstract type Option{T} <: Monad end
type Some{T} <: Option{T}
value::T
end
type None{T} <: Option{T}
end
I can’t figure out why that error is given? Can someone explain it to me? Thanks