Bump to doxygen 1.9.2
[platform/upstream/doxygen.git] / testing / 074_ref.cpp
1 // objective: test \ref command in combination with const
2 // check: struct_foo.xml
3 // check: namespacens.xml
4
5 #include <initializer_list>
6
7 /** @brief Foo class.
8  *
9  *  @see @ref Foo::Foo() constructor for details.
10  *  @see @ref Foo constant.
11  *  @see @ref operator<<(int) "less than operator".
12  *  @see @ref operator<<(int) const "const less than operator".
13  *  @see @ref operator()(int) "call operator".
14  *  @see @ref operator()(int) const "const call operator".
15  *  @see @ref operator&=(const Foo&) "and equal operator".
16  *  @see @ref operator&=(const Foo&) const "const and equal operator".
17  *  @see @ref operator->*(int *) "member pointer operator".
18  */
19 struct Foo {
20   /** Constructor */
21   Foo();
22   /**
23    * @brief Fun of two
24    *
25    * - fun() const
26    * - @ref fun() const
27    * - @ref fun() const "title"
28    */
29   static Foo fun(Foo a, Foo b);
30
31   /** overloaded less than operator */
32   Foo& operator<< (int i);
33
34   /** overloaded const less than operator */
35   const Foo& operator<< (int i) const;
36
37   /** overloaded call operator */
38   int operator()(int i);
39
40   /** overloaded call operator */
41   int operator()(int i) const;
42
43   /** and equal operator */
44   Foo& operator&=(const Foo& rhs);
45
46   /** and equal operator */
47   const Foo& operator&=(const Foo& rhs) const;
48
49   /** Member pointer operator */
50   int* operator->*(int *p);
51
52   /** @brief Fun with itself */
53   Foo fun() const;
54 };
55
56 /**
57 @brief A namespace
58
59 - Link to an UDL w/o spaces: @link operator""_op @endlink
60 - Link to an UDL with spaces: @link operator""_oq @endlink
61 - Link to a function with spaces: @ref foo(std::initializer_list< int* >)
62 - Link to a function w/o spaces: @ref foo(std::initializer_list<int*>)
63 */
64 namespace ns {
65
66 /** @brief An operator */
67 int operator""_op(unsigned long long);
68
69 /** @brief Another operator */
70 int operator "" _oq(unsigned long long);
71
72 /** @brief Function */
73 void foo(std::initializer_list<int*>);
74
75 }