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.
This PR adds an assortment of fixes for the Scala mode (including one performance bug fix!). I've been running with this mode as my primary mode for Scala across several non-trivial codebases for quite some time now, and it works much better than the original. The exact features are split out into individual commits, so if you don't want one (or more), we can rebase some things away. I do recommend taking the whole package though.
self
isn't a keyword in Scala, thoughsuper
andthis
are({ type λ[α] = EitherT[Task, Throwable, α] })#λ
) are a very common pattern in highly abstracted Scala. I added a bit of syntax highlighting which parses out the boilerplate and highlights it as a comment, while highlighting the rest as a type definition. This makes things FAR more readable. It only works for lambdas of up to arity-2 and only using greek letters (conventional).new
regex, which was overly greedy and could sometimes consume the entire file before backtracking."""phooey"""".length
now highlights as you would expect.