[cfe-dev] -WDocumentation warning on multiple defs in a single comment block

Marshall Clow mclow.lists at gmail.com
Thu Jan 17 09:36:12 PST 2013


I have a chunk of code that looks like this:

	/*! 
		\struct hex_decode_error 
		\brief  Base exception class for all hex decoding errors 
	
		\struct non_hex_input    
		\brief  Thrown when a non-hex value (0-9, A-F) encountered when decoding.
					Contains the offending character
	
		\struct not_enough_input 
		\brief  Thrown when the input sequence unexpectedly ends
	
	*/
	struct hex_decode_error : virtual boost::exception, virtual std::exception {};
	struct not_enough_input : virtual hex_decode_error {};
	struct non_hex_input    : virtual hex_decode_error {};


Doxygen processes it correctly.
TOT clang (using -Wdocumentation) warns about duplicate \brief comments.

Specifically, it says:
	warning: duplicated command "\brief" [-Wdocumentation]

Obviously, I can break this up into three comment blocks, but why should I have to?

-- Marshall

Marshall Clow     Idio Software   <mailto:mclow.lists at gmail.com>

A.D. 1517: Martin Luther nails his 95 Theses to the church door and is promptly moderated down to (-1, Flamebait).
        -- Yu Suzuki





More information about the cfe-dev mailing list