Skip to content
This repository has been archived by the owner on May 29, 2024. It is now read-only.

Commit

Permalink
nit(qualifiedtype): assert return type
Browse files Browse the repository at this point in the history
This improves type inference, since it seems that the compiler can't
quite figure out the typeify function by itself.
  • Loading branch information
tecosaur committed May 23, 2024
1 parent 8f3a61f commit c3da8e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/model/qualifiedtype.jl
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ end
Convert `qt` to a `Type` available in `mod`, if possible.
If this cannot be done, `nothing` is returned instead.
"""
function typeify(qt::QualifiedType; mod::Module=Main, shoulderror::Bool=false)
function typeify(qt::QualifiedType; mod::Module=Main, shoulderror::Bool=false)::Union{Type, Nothing}
mod = if qt.root === :Main
mod
elseif isdefined(mod, qt.root)
Expand Down

0 comments on commit c3da8e5

Please sign in to comment.