summaryrefslogtreecommitdiff
path: root/tests/warn/annotationparser.h
blob: 12dc4cc71d0b51ae8502b6044b17589add59b8fb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include "common.h"

/**
 * test_symbol_thrice_documented:
 *
 * Documenting the same thing multiple times can lead to subtle bugs.
 * For example, one comment block might have correct annotations...
 **/
void test_symbol_thrice_documented();

/**
 * test_symbol_thrice_documented:
 *
 * ...and a different comment block (out of sync with the above) might have
 * no annotations at all. The last comment block seen by the parser "wins"...
 **/

// EXPECT:11: Warning: Test: multiple comment blocks documenting 'test_symbol_thrice_documented:' identifier (already seen at annotationparser.h:3).


/**
 * test_symbol_thrice_documented:
 *
 * ...and yet another one.
 **/

// EXPECT:21: Warning: Test: multiple comment blocks documenting 'test_symbol_thrice_documented:' identifier (already seen at annotationparser.h:11).