You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
679 B
36 lines
679 B
! Test printpreprocessed action
|
|
|
|
! REQUIRES: new-flang-driver
|
|
|
|
!--------------------------
|
|
! FLANG DRIVER (flang-new)
|
|
!--------------------------
|
|
! RUN: %flang-new -E %s 2>&1 | FileCheck %s
|
|
|
|
!-----------------------------------------
|
|
! FRONTEND FLANG DRIVER (flang-new -fc1)
|
|
!-----------------------------------------
|
|
! RUN: %flang-new -fc1 -E %s 2>&1 | FileCheck %s
|
|
|
|
|
|
!-----------------------
|
|
! EXPECTED OUTPUT
|
|
!-----------------------
|
|
! flang-new -E %s
|
|
! CHECK:program a
|
|
! CHECK-NOT:program b
|
|
! CHECK-NEXT:x = 1
|
|
! CHECK-NEXT:write(*,*) x
|
|
! CHECK-NEXT:end
|
|
|
|
! Preprocessed-file.F:
|
|
#define NEW
|
|
#ifdef NEW
|
|
program A
|
|
#else
|
|
program B
|
|
#endif
|
|
x = 1
|
|
write(*,*) x
|
|
end
|