nvim-colorizer.lua icon indicating copy to clipboard operation
nvim-colorizer.lua copied to clipboard

Bug: tan() function gets colorized

Open Riksu9000 opened this issue 3 years ago • 1 comments

A function named tan() gets colorized. This isn't referring to a color, so I expect it to not get colorized. Maybe this can be fixed by checking for a trailing parenthesis.

Screenshots image

Neovim Version: 0.8.1

Colorizer Version: 760e27df4dd966607e8fb7fd8b6b93e3c7d2e193

Riksu9000 avatar Dec 29 '22 09:12 Riksu9000

Given the dumb nature of the color name algorithm, that's intended. Obviously i could add a check for a trailing parenthesis. But there are too many conditions that could happen, like what if [ or { or something, trailing or leading.

So i have no intention of adding a hacky fix like that.

You should disable names for that file type specifically.

Akianonymus avatar Feb 27 '23 07:02 Akianonymus