Skip to content

Commit 95a1eae

Browse files
committed
Fix a couple more julia-0.5 deprecations
1 parent 15a0a20 commit 95a1eae

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/loadsave.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ const sym2loader = Dict{Symbol,Vector{Symbol}}()
22
const sym2saver = Dict{Symbol,Vector{Symbol}}()
33

44
function is_installed(pkg::Symbol)
5-
isdefined(pkg) && isa(Main.(pkg), Module) && return true # is a module defined in Main scope
5+
isdefined(pkg) && isa(@compat(getfield(Main, pkg)), Module) && return true # is a module defined in Main scope
66
path = Base.find_in_path(string(pkg)) # hacky way to determine if a Package is installed
77
path == nothing && return false
88
return isfile(path)
@@ -11,7 +11,7 @@ end
1111
function checked_import(pkg::Symbol)
1212
!is_installed(pkg) && throw(NotInstalledError(pkg, ""))
1313
!isdefined(Main, pkg) && eval(Main, Expr(:import, pkg))
14-
return Main.(pkg)
14+
return @compat(getfield(Main, pkg))
1515
end
1616

1717

src/query.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -426,8 +426,8 @@ function iter_eq(A, B)
426426
for _=1:length(A)
427427
a=A[i]; b=B[j]
428428
a == b && (i+=1; j+=1; continue)
429-
a == '\r' && (i+=1; continue) # this seems like the shadiest solution to deal with windows \r\n
430-
b == '\r' && (j+=1; continue)
429+
a == @compat(UInt32('\r')) && (i+=1; continue) # this seems like the shadiest solution to deal with windows \r\n
430+
b == @compat(UInt32('\r')) && (j+=1; continue)
431431
return false #now both must be unequal, and no \r windows excemption any more
432432
end
433433
true

0 commit comments

Comments
 (0)