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 #line functionality with macro expansion required 11 12 #define LINE_NO 5 13 #define FILE_NAME "a_nonexisting_file.cpp" 14 #line LINE_NO FILE_NAME 15 16 //R 17 //E a_nonexisting_file.cpp(8): fatal error: encountered #error directive or #pragma wave stop(): This error should occur at line 8 of "a_nonexisting_file.cpp" 18 #error This error should occur at line 8 of "a_nonexisting_file.cpp" 19 20 //H 10: t_2_004.cpp(12): #define 21 //H 08: t_2_004.cpp(12): LINE_NO=5 22 //H 10: t_2_004.cpp(13): #define 23 //H 08: t_2_004.cpp(13): FILE_NAME="a_nonexisting_file.cpp" 24 //H 10: t_2_004.cpp(14): #line 25 //H 01: t_2_004.cpp(12): LINE_NO 26 //H 02: 5 27 //H 03: 5 28 //H 01: t_2_004.cpp(13): FILE_NAME 29 //H 02: "a_nonexisting_file.cpp" 30 //H 03: "a_nonexisting_file.cpp" 31 //H 17: 5 "a_nonexisting_file.cpp" (5, "a_nonexisting_file.cpp") 32 //H 10: a_nonexisting_file.cpp(8): #error 33 //H 16: This error should occur at line 8 of "a_nonexisting_file.cpp" 34 //H 18: boost::wave::preprocess_exception 35