diff --git a/base/exports.jl b/base/exports.jl index c051eb2f5b480..2f87c86d5976a 100644 --- a/base/exports.jl +++ b/base/exports.jl @@ -1377,7 +1377,6 @@ export # nullable types isnull, - nulled, # Macros @__FILE__, diff --git a/base/nullable.jl b/base/nullable.jl index e92825e8f50a4..f5e560476f557 100644 --- a/base/nullable.jl +++ b/base/nullable.jl @@ -13,8 +13,6 @@ Nullable{T}(value::T) = Nullable{T}(value) eltype{T}(::Type{Nullable{T}}) = T -const nulled = Nullable{Union()}() - function convert{T}(::Type{Nullable{T}}, x::Nullable) return isnull(x) ? Nullable{T}() : Nullable{T}(convert(T, get(x))) end diff --git a/doc/stdlib/base.rst b/doc/stdlib/base.rst index aafb19d69f53b..a4317baaed087 100644 --- a/doc/stdlib/base.rst +++ b/doc/stdlib/base.rst @@ -571,11 +571,6 @@ Nullables Is the ``Nullable`` object ``x`` null, i.e. missing a value? -.. data:: nulled - - A constant ``Nullable`` value in the null (missing value) state. Used, for example, - as a compact way to initialize ``Nullable`` fields: ``x.field = nulled``. - System ------ diff --git a/test/nullable.jl b/test/nullable.jl index 66d6f1b46016f..42ef7f740427e 100644 --- a/test/nullable.jl +++ b/test/nullable.jl @@ -249,8 +249,3 @@ for T in types @test isa(convert(Nullable{Number}, Nullable(one(T))), Nullable{Number}) @test isa(convert(Nullable{Any}, Nullable(one(T))), Nullable{Any}) end - -@test isnull(nulled) -@test_throws NullException get(nulled) -@test isa(convert(Nullable{Int}, nulled), Nullable{Int}) -@test isnull(convert(Nullable{Int}, nulled))