t_1_030.cpp 1.1 KB

123456789101112131415161718192021222324252627282930313233
  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. // Tests, whether an empty macro prevents another macro from expansion
  9. #define EMPTY()
  10. #define SCAN(x) x
  11. #define MACRO(x) (x)
  12. //R #line 17 "t_1_030.cpp"
  13. SCAN( MACRO EMPTY() )(1) //R (1)
  14. //H 10: t_1_030.cpp(12): #define
  15. //H 08: t_1_030.cpp(12): EMPTY()=
  16. //H 10: t_1_030.cpp(13): #define
  17. //H 08: t_1_030.cpp(13): SCAN(x)=x
  18. //H 10: t_1_030.cpp(14): #define
  19. //H 08: t_1_030.cpp(14): MACRO(x)=(x)
  20. //H 00: t_1_030.cpp(17): SCAN( MACRO EMPTY() ), [t_1_030.cpp(13): SCAN(x)=x]
  21. //H 00: t_1_030.cpp(17): EMPTY(), [t_1_030.cpp(12): EMPTY()=]
  22. //H 02:
  23. //H 03: _
  24. //H 02: MACRO
  25. //H 03: MACRO
  26. //H 00: t_1_030.cpp(17): MACRO(1), [t_1_030.cpp(14): MACRO(x)=(x)]
  27. //H 02: (1)
  28. //H 03: (1)