This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug preprocessor/15638] gcc should have option to treat missing headers as fatal



------- Comment #15 from jsm28 at gcc dot gnu dot org  2009-03-31 12:43 -------
Subject: Bug 15638

Author: jsm28
Date: Tue Mar 31 12:43:29 2009
New Revision: 145341

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=145341
Log:
        PR preprocessor/15638
gcc:
        * c-common.c (c_cpp_error): Handle CPP_DL_FATAL.

gcc/fortran:
        * cpp.c (cb_cpp_error): Handle CPP_DL_FATAL.

gcc/testsuite:
        * gcc.dg/cpp/missing-header-1.c: New test.
        * gcc.dg/cpp/include2.c: Only test #include <>.  Expect
        "compilation terminated" message.
        * gcc.dg/cpp/include2a.c: New test.  Copy of include2.c but only
        test #include "".
        * gcc.dg/pch/counter-2.c, gcc.dg/pch/valid-1.c,
        gcc.dg/pch/valid-2.c, gcc.dg/pch/warn-1.c: Expect "compilation
        terminated" message.

libcpp:
        * files.c (_cpp_find_file): Call open_file_failed after diagnosing
        invalid PCH.
        (open_file_failed): Make error for missing file fatal.
        * include/cpplib.h (CPP_DL_FATAL): Define.

Added:
    trunk/gcc/testsuite/gcc.dg/cpp/include2a.c
    trunk/gcc/testsuite/gcc.dg/cpp/missing-header-1.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/c-common.c
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/cpp.c
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/gcc.dg/cpp/include2.c
    trunk/gcc/testsuite/gcc.dg/pch/counter-2.c
    trunk/gcc/testsuite/gcc.dg/pch/valid-1.c
    trunk/gcc/testsuite/gcc.dg/pch/valid-2.c
    trunk/gcc/testsuite/gcc.dg/pch/warn-1.c
    trunk/libcpp/ChangeLog
    trunk/libcpp/files.c
    trunk/libcpp/include/cpplib.h


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15638


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]