YoYoGames / GameMaker-Bugs

Public tracking for GameMaker bugs
22 stars 8 forks source link

Similar to TODO support, highlight other keywords in comments like FIXME, NOTE and WARNING #7050

Open meseta opened 1 month ago

meseta commented 1 month ago

Is your feature request related to a problem?

Similar to #3953, modern IDEs and code editors often support highlighting of keywords such as FIXME, NOTE, and WARNING

Describe the solution you'd like

The current open beta build highlights comment lines that include "TODO" and "BUG" in blue.

The solution I would like would be to additionally highlight comment lines that include "FIXME", "NOTE", "WARNING", and "XXX". Ideally in different colors appropriate to their severity (e.g. WARNING and BUG in red)

Describe alternatives you've considered

No response

Additional context

No response

YYDan commented 1 month ago

"XXX" - what would that even mean to anyone? ;) Do you actually mean just "Anything in all-caps", or specifically the string "XXX" ?

And "FIXME" is better-communicated if it's separated as the proper "TODO" or a "BUG", no?

meseta commented 1 month ago

by XXX, I mean literally the string "XXX"

XXX and FIXME are just some common conventions found in other IDEs and editors, like VSCode. For example both VSCode, and an extension I like to use that gathers all these into a list, makes it very easy to locate them in the project: here are some screenshots of what they look like:

The XXX text highlighted in the code image

A couple different ways to view a list of all of the text in the project image image

I personally use XXX to mark code that I'm actively refactoring and need to make a note to myself to revisit that line as I work. I can then search for any remaining ones. Having it automatically highlighted makes it very useful to quickly find the lines of code I've marked.

I personally use FIXME to mark code that needs to be optimized or an item of technical debt, which is not a BUG, and arguably different to a TODO which I use to mark code that isn't yet implemented.

I think it is useful to have these different highlighted tokens available for use, I'm sure others have different conventions they follow, but having more of them provides flexibility on picking a convention, rather than having the IDE enforce a specific convention

There's some discourse on the internet about these tokens. For example in this thread: https://stackoverflow.com/questions/1452934/what-is-the-meaning-of-xxx-in-code-comments you can see that XXX and FIXME are established conventions across several languages and tools