Skip to content

Commit

Permalink
guard `isempty (close #41656) (#41752)
Browse files Browse the repository at this point in the history
  • Loading branch information
bicycle1885 authored Aug 2, 2021
1 parent bdacfa2 commit 4c3829d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion contrib/generate_precompile.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This file is a part of Julia. License is MIT: https://julialang.org/license

if isempty(Base.ARGS) || Base.ARGS[1] !== "0"
if Base.isempty(Base.ARGS) || Base.ARGS[1] !== "0"
Sys.__init_build()
# Prevent this from being put into the Main namespace
@eval Module() begin
Expand Down
2 changes: 2 additions & 0 deletions test/misc.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1000,3 +1000,5 @@ let script = :(let ptr = Ptr{Cint}(ccall(:jl_mmap, Ptr{Cvoid},
@test !success(`$(Base.julia_cmd()) -e $script`)
end

# issue #41656
@test success(`$(Base.julia_cmd()) -e 'isempty(x) = true'`)

0 comments on commit 4c3829d

Please sign in to comment.