I implemented legacy "token pasting" via line continuation for
call prefix&
&MACRO&
&suffix(1)
in a recent patch; this patch addresses the related cases
call prefix&
&MACRO&
&(1)
and
call &
&MACRO&
&suffix(1)
Fixes the latest https://github.com/llvm/llvm-project/issues/79590.
15 lines
350 B
Fortran
15 lines
350 B
Fortran
! RUN: %flang -E %s 2>&1 | FileCheck %s
|
|
! CHECK: res = (777)
|
|
! KWM call name split across continuation, with leading &
|
|
integer, parameter :: KWM = 666
|
|
#define KWM 777
|
|
integer :: res
|
|
res = (KW&
|
|
&M)
|
|
if (res .eq. 777) then
|
|
print *, 'pp105.F90 yes'
|
|
else
|
|
print *, 'pp105.F90 no: ', res
|
|
end if
|
|
end
|