Differentiate syntax between function definitions and function calls #40
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Goals:
as function calls
those definitions with a rather bold color, applying the same coloring to
all functions calls results in visual noise
State of syntax highlighting:
definitions (
entity.name.function
) but says nothing about function callsThis PR combines portions of #30 and #38 that have similar goals.
PR #30 by itself did not fully accomplish my goals because function calls are
still annotated with
entity.name.function.elixir
which is highlighted as afunction definition
PR #38 changed the function call names, but it changed it to a non-standard scope.
So in this PR we change the
entity.name.function.elixir
toentity.name.function-call.elixir
which allows customization, but is a scopethat that does not have default coloring in most themes (while still being
semantically similar).
Also Ruby's syntax uses the similar
entity.name.function-call.ruby
:https://github.com/rubyide/vscode-ruby/blob/b232cfd0c96f41ceab72655dcfa17dab40c05562/packages/vscode-ruby/syntaxes/ruby.cson.json#L2243
Related comment: elixir-editors/elixir-tmbundle#179 (comment)
cc: @thiagomajesk, @CaiqueMitsuoka, @chrismccord
[1] https://macromates.com/manual/en/language_grammars