Skip to content

REPL: improve tab-completion of :-prefixed commands (fixes scala/bug#12264)#9521

Merged
SethTisue merged 1 commit intoscala:2.13.xfrom
jxnu-liguobin:fix-12264
Mar 12, 2021
Merged

REPL: improve tab-completion of :-prefixed commands (fixes scala/bug#12264)#9521
SethTisue merged 1 commit intoscala:2.13.xfrom
jxnu-liguobin:fix-12264

Conversation

@jxnu-liguobin
Copy link
Member

Valid only for question mark commands. The question mark command has separate parsing logic and uses the Jline3 default parser. and Jline3 will parse it into word :p. Jline3 uses prefix matching or contains matching, so :p cannot be matched to candidate, because the value of candidate is paste and power.

The input and output of : p can be matched because the word parsed by Jline3 is p, and it's collaborator think Jline3 is designed correctly. We should modify the candidate.

@scala-jenkins scala-jenkins added this to the 2.13.6 milestone Feb 25, 2021
@SethTisue SethTisue self-requested a review February 25, 2021 16:00
@SethTisue SethTisue added the tool:REPL Changes to the Scala REPL shell label Feb 25, 2021
@SethTisue SethTisue changed the title Fixes scala/bug#12264 REPL: improve tab-completion of :-prefixed commands (fixes scala/bug#12264) Feb 25, 2021
@SethTisue
Copy link
Member

(sorry this is taking me so long to get to — I'm backlogged)

@jxnu-liguobin
Copy link
Member Author

(sorry this is taking me so long to get to — I'm backlogged)

hh

@SethTisue
Copy link
Member

this LGTM — can you squash it into a single commit? then let's merge

@jxnu-liguobin
Copy link
Member Author

this LGTM — can you squash it into a single commit? then let's merge

ok

@SethTisue SethTisue merged commit 93ec1f0 into scala:2.13.x Mar 12, 2021
@SethTisue
Copy link
Member

excellent -- thank you!

@jxnu-liguobin jxnu-liguobin deleted the fix-12264 branch March 12, 2021 14:21
@som-snytt
Copy link
Contributor

The "organize imports" is extraneous. That is a matter of style, but in the absence of a project scalafix, I would avoid it as a rule.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tool:REPL Changes to the Scala REPL shell

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants