Ensure that #include FOO undergoes macro replacement. But, as is the case with C/C++, continue to not perform macro replacement in a #include directive with <angled brackets>.
19 lines
539 B
Fortran
19 lines
539 B
Fortran
! RUN: %flang -I%S -E %s 2>&1 | FileCheck %s
|
|
! CHECK-NOT: :3:
|
|
#include <empty.h> ! comment
|
|
! CHECK-NOT: :5:
|
|
#include <empty.h> /* comment */
|
|
! CHECK-NOT: :7:
|
|
#include <empty.h> !comment
|
|
! CHECK: :9:10: portability: #include: extra stuff ignored after file name
|
|
#include <empty.h> comment
|
|
! CHECK-NOT: :11:
|
|
#include "empty.h" ! comment
|
|
! CHECK-NOT: :13:
|
|
#include "empty.h" /* comment */
|
|
! CHECK-NOT: :15:
|
|
#include "empty.h" !comment
|
|
! CHECK: :17:10: portability: #include: extra stuff ignored after file name
|
|
#include "empty.h" comment
|
|
end
|