Skip to content

Commit b482b09

Browse files
authored
fix #30234, don't resolve bindings when tab-completing using (#30254)
1 parent 92e82b6 commit b482b09

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

stdlib/REPL/src/REPLCompletions.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -665,7 +665,7 @@ function completions(string, pos, context_module=Main)::Completions
665665
end
666666
end
667667
end
668-
ffunc = (mod,x)->(isdefined(mod, x) && isa(getfield(mod, x), Module))
668+
ffunc = (mod,x)->(Base.isbindingresolved(mod, x) && isdefined(mod, x) && isa(getfield(mod, x), Module))
669669
comp_keywords = false
670670
end
671671
startpos == 0 && (pos = -1)

stdlib/REPL/test/replcompletions.jl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,8 @@ end
105105
let s = "using REP"
106106
c, r = test_complete(s)
107107
@test count(isequal("REPL"), c) == 1
108+
# issue #30234
109+
@test !Base.isbindingresolved(Main, :tanh)
108110
end
109111

110112
let s = "Comp"

0 commit comments

Comments
 (0)