Skip to content

Commit 62ea34f

Browse files
Revert "REPL: hide any prints to stdio during complete_line (#55959)"
This reverts commit 84a2458.
1 parent a007e80 commit 62ea34f

File tree

1 file changed

+2
-15
lines changed

1 file changed

+2
-15
lines changed

stdlib/REPL/src/LineEdit.jl

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -366,14 +366,7 @@ end
366366
# Prompt Completions & Hints
367367
function complete_line(s::MIState)
368368
set_action!(s, :complete_line)
369-
# suppress stderr/stdout prints during completion computation
370-
# i.e. ambiguous qualification warnings that are printed to stderr
371-
# TODO: remove this suppression once such warnings are better handled
372-
# TODO: but before that change Pipe to devnull once devnull redirects work for JL_STDERR etc.
373-
completions_exist = redirect_stdio(;stderr=Pipe(), stdout=Pipe()) do
374-
complete_line(state(s), s.key_repeats, s.active_module)
375-
end
376-
if completions_exist
369+
if complete_line(state(s), s.key_repeats, s.active_module)
377370
return refresh_line(s)
378371
else
379372
beep(s)
@@ -391,13 +384,7 @@ function check_for_hint(s::MIState)
391384
end
392385

393386
completions, partial, should_complete = try
394-
# suppress stderr/stdout prints during completion computation
395-
# i.e. ambiguous qualification warnings that are printed to stderr
396-
# TODO: remove this suppression once such warnings are better handled
397-
# TODO: but before that change Pipe to devnull once devnull redirects work for JL_STDERR etc.
398-
completions, partial, should_complete = redirect_stdio(;stderr=Pipe(), stdout=Pipe()) do
399-
complete_line(st.p.complete, st, s.active_module; hint = true)::Tuple{Vector{String},String,Bool}
400-
end
387+
complete_line(st.p.complete, st, s.active_module; hint = true)::Tuple{Vector{String},String,Bool}
401388
catch
402389
@debug "error completing line for hint" exception=current_exceptions()
403390
return clear_hint(st)

0 commit comments

Comments
 (0)