LuaLS / LuaLS/lua-language-server

Mass renaming proposal

Offen
#1,404 10 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

suggestion
Vorherrschende Sprache
Lua
Sterne
4.4k
Forks
442
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

There are a number of settings, diagnostics, and more that have unclear names that I think can be improved. This issue serves to propose new names for these items so that they can all be tracked in one place and implemented at once to minimize the number of breaking releases that would need to be released.

Settings

  • completion.displayContext -> completion.peekDefinition
    • There is already a Peek Definition command in VS Code that has a similar function and I think naming it the same will help people understand its function without confusing the two as they are triggered entirely differently.
  • diagnostics.disable -> REMOVE
  • diagnostics.groupFileStatus -> REMOVE
  • diagnostics.groupSeverity -> REMOVE
  • diagnostics.ignoreFiles -> diagnostics.diagnoseIgnored
  • diagnostics.libraryFiles -> diagnostics.diagnoseLibraries
  • diagnostics.neededFileStatus -> diagnostics.config (Rework functionality)
  • diagnostics.severity (Rework functionality)
  • diagnostics.workspaceDelay -> diagnostics.delay
  • hint.setType -> hint.assignType
  • hover.enumsLimit -> hover.typesLimit
  • hover.previewFields -> hover.peekFields
  • runtime.special -> runtime.aliases
  • workspace.checkThirdParty -> workspace.checkEnvConfigs
  • workspace.ignoreDir -> workspace.ignore
  • workspace.library -> workspace.libraries
  • workspace.maxPreload -> workspace.maxFiles
  • workspace.preloadFileSize -> workspace.maxFileSize
  • workspace.userThirdParty -> workspace.envConfig

Diagnostics

I imagine there is a good reason abiguity-1 is named how it is 😄 I see they all have at least 1 hyphen so I guess that is a limitation with how they are parsed?

  • unknown-diag-code -> unknown-diagnostic
  • cast-local-type -> local-cast-mismatch

Syntax Errors

Luckily these can probably be changed with very little impact on the user and most people likely would not have any settings related to these.

  • err-assign-as-eq -> assign-with-equals
  • err-c-long-comment -> multiline-comment-prefix
  • err-comment-prefix -> comment-prefix
  • err-do-as-then -> then-as-do
  • err-eq-as-assign -> equality-with-assign
  • err-esc -> unknown-escape
  • err-nonstandard-symbol -> non-standard-symbol
  • err-then-as-do -> do-as-then
  • exp-in-action -> unexpected-expression
  • keyword -> reserved
  • miss-esc-x -> miss-hex-value
  • miss-exp -> miss-expression

newfield-call and newline-call are not easy to understand but I can't think of anything that does a better job 🤔

I don't even know what these do: unexpect-efunc-name, unexpect-lfunc-name


Please let me know what you think and feel free to suggest other names.

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Beginne damit, die in diesem Issue vorgeschlagenen Einstellungen, Diagnosecodes und Umbenennungen von Syntaxfehlern sowie die verknüpften Issues #1364 und #1384 zu überprüfen. Bestimme zunächst, welche Namen und Änderungen an der Funktionalität akzeptiert werden; als erledigt könnte die Aufgabe erst mit einem abgestimmten, vollständigen Umbenennungsplan gelten, nicht mit einer isolierten Änderung.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
lua
Bereich
devtools
Issue-Typ
Refactoring
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
25/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.