Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

XXX in C++ comments

In vim, whenever I add a comment like this

int somevar = 100; //XXX Some Comment Here

The "XXX" part of my comment gets automatically highlighted. "TODO" in a comment also gets highlighted similarly. I've used these myself quite widely to mark todos/draw attention, but never bothered to learn what makes "XXX" and "TODO" special. What makes these two words special?

Are there are other special words in comments that automatically get highlighted?

like image 841
DigitalEye Avatar asked May 07 '14 05:05

DigitalEye


People also ask

What does Fixme mean?

To exact revenge upon or punish someone.

What is Fixme comment?

FIXME comments are often used to indicate code that does not work correctly or that may not work in all supported environments. This may be necessary during the implementation of new functionality but FIXME comments should not be present in stable code.

What does todo mean in code?

In general, a TODO is written to tell future maintainers about something important: something that should be added, or should be changed, or should not be forgotten. The intention is often to increase the quality of the code. Sometimes a TODO comment can save you a lot of time!


1 Answers

  • TODO to indicate planned enhancements.
  • XXX to warn other programmers of problematic or misguiding code.

Source.

like image 89
alex Avatar answered Oct 23 '22 16:10

alex