mathworks / MATLAB-Language-grammar

This repository contains a regular expression based language grammar for MATLAB to be used by GitHub Linguist for highlighting MATLAB code on GitHub
49 stars 17 forks source link

"end" keyword not being tokenized correctly #80

Closed goldrik closed 2 months ago

goldrik commented 3 months ago

In this screenshot, I have two identical if statements. They are defined within a larger function.

I noticed the "end" keyword for the second if statement was not colored correctly. Here are the editor tokens for that "end"

Screenshot 2024-05-02 at 1 17 53 PM 3

Here is what they are for the first if statement (above). This one is colored correctly

Screenshot 2024-05-02 at 1 17 42 PM 3

The difference between the two is that the first one has an empty line right above the "end" keyword"