purescript-contrib / purescript-vim

Syntax highlighting and indentation for PureScript
BSD 2-Clause "Simplified" License
154 stars 35 forks source link

Highlighting explicit types in multiline import #53

Closed unclechu closed 6 years ago

unclechu commented 6 years ago

screenshot from 2018-02-16 04-38-18 screenshot from 2018-02-16 04-38-07

unclechu commented 6 years ago

as keyword also have this issue: screenshot from 2018-02-18 04-33-23 screenshot from 2018-02-18 04-33-15

unclechu commented 6 years ago

Also if I just rename import to module it goes okay (maybe some parts of regex from module could be taken to fix import regex). screenshot from 2018-02-22 03-23-28 screenshot from 2018-02-22 03-23-37

coot commented 6 years ago

Please try the new version. It now consistently highlights classes, kinds, and functions within import and module syntax groups.

unclechu commented 6 years ago

@coot now I have both this issue and new one, all module names have similar color as import/module keyword. screenshot from 2018-03-11 18-55-28 screenshot from 2018-03-11 18-55-35 So, I guess this issue supposed to be reopened.

coot commented 6 years ago

The bottom screenshare is how it is supposed to look like. You might differentiate the import and module by having different colours for purscriptImportKeyword (by default linked to purescriptKeyword) and purescriptModuleName (by default linked to Include) highlight classes.

The top one looks different here, ReactClass and other that start with an uppercase letter have purescritpConstructor syntax group and other have purescriptIdentifier. It's a bit different when they are in the same line (which should be fixed), but still the default highlighting is consistent.