• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*=============================================================================
2     Boost.Wave: A Standard compliant C++ preprocessor library
3     http://www.boost.org/
4 
5     Copyright (c) 2001-2012 Hartmut Kaiser. Distributed under the Boost
6     Software License, Version 1.0. (See accompanying file
7     LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
8 =============================================================================*/
9 
10 // Tests the stringize operator in conjunction with varidic macros
11 
12 //O --variadics
13 
14 #define STR(...) #__VA_ARGS__
15 
16 //R #line 17 "t_1_033.cpp"
17 STR(1, 2, 3)            //R "1, 2, 3"
18 STR(1,2,3)              //R "1,2,3"
19 STR(1 , 2 , 3)          //R "1 , 2 , 3"
20 STR( 1  ,   2  ,   3 )  //R "1 , 2 , 3"
21 
22 //H 10: t_1_033.cpp(14): #define
23 //H 08: t_1_033.cpp(14): STR(...)=#__VA_ARGS__
24 //H 00: t_1_033.cpp(17): STR(1, 2, 3), [t_1_033.cpp(14): STR(...)=#__VA_ARGS__]
25 //H 02: "1, 2, 3"
26 //H 03: "1, 2, 3"
27 //H 00: t_1_033.cpp(18): STR(1,2,3), [t_1_033.cpp(14): STR(...)=#__VA_ARGS__]
28 //H 02: "1,2,3"
29 //H 03: "1,2,3"
30 //H 00: t_1_033.cpp(19): STR(1 , 2 , 3), [t_1_033.cpp(14): STR(...)=#__VA_ARGS__]
31 //H 02: "1 , 2 , 3"
32 //H 03: "1 , 2 , 3"
33 //H 00: t_1_033.cpp(20): STR( 1 , 2 , 3 ), [t_1_033.cpp(14): STR(...)=#__VA_ARGS__]
34 //H 02: "1 , 2 , 3"
35 //H 03: "1 , 2 , 3"
36