brintos

brintos / llvm-project-archived public Read only

0
0
Text · 813 B · 4ac58bf Raw
29 lines · plain
1! Note: flang will issue warnings for the following subroutines. These2! are accepted regardless to maintain backwards compatibility with3! other Fortran implementations.4 5! RUN: bbc -emit-fir %s -o - | FileCheck %s6 7! CHECK-LABEL: func @_QPs1() {8! CHECK: fir.convert %{{.*}} : ((!fir.boxchar<1>) -> ()) -> ((!fir.ref<f32>) -> ())9 10! Pass a REAL by reference to a subroutine expecting a CHARACTER11subroutine s112  call s3(r)13end subroutine s114 15! CHECK-LABEL: func @_QPs2(16! CHECK: fir.convert %{{.*}} : ((!fir.boxchar<1>) -> ()) -> ((!fir.ref<f32>) -> ())17 18! Pass a REAL, POINTER data reference to a subroutine expecting a CHARACTER19subroutine s2(p)20  real, pointer :: p21  call s3(p)22end subroutine s223 24! CHECK-LABEL: func @_QPs3(25! CHECK-SAME: !fir.boxchar<1>26subroutine s3(c)27  character(8) c28end subroutine s329