t_1_011.cpp 1.1 KB

1234567891011121314151617181920212223242526272829303132
  1. /*=============================================================================
  2. Boost.Wave: A Standard compliant C++ preprocessor library
  3. http://www.boost.org/
  4. Copyright (c) 2001-2012 Hartmut Kaiser. Distributed under the Boost
  5. Software License, Version 1.0. (See accompanying file
  6. LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  7. =============================================================================*/
  8. // Test if macros at not used parameter positions are expanded correctly
  9. #define MACRO() /**/
  10. #define ID(x) // parameter not used at all
  11. #define CAT(x) X ## x // expanded parameter not used
  12. ID( MACRO(*) )
  13. //R #line 19 "t_1_011.cpp"
  14. //R XMACRO(*)
  15. CAT( MACRO(*) )
  16. //H 10: t_1_011.cpp(12): #define
  17. //H 08: t_1_011.cpp(12): MACRO()=
  18. //H 10: t_1_011.cpp(13): #define
  19. //H 08: t_1_011.cpp(13): ID(x)=
  20. //H 10: t_1_011.cpp(14): #define
  21. //H 08: t_1_011.cpp(14): CAT(x)=X ## x
  22. //H 00: t_1_011.cpp(16): ID( MACRO(*) ), [t_1_011.cpp(13): ID(x)=]
  23. //H 02:
  24. //H 03: _
  25. //H 00: t_1_011.cpp(19): CAT( MACRO(*) ), [t_1_011.cpp(14): CAT(x)=X ## x]
  26. //H 02: XMACRO(*)
  27. //H 03: XMACRO(*)