20 lines · plain
1! Test that the shape of the elemental call is properly2! computed as being rank 1, even though the only dummy3! argument is optional.4 5! RUN: bbc -emit-fir %s -o - | FileCheck %s6! RUN: bbc -emit-hlfir %s -o - | FileCheck %s7 8subroutine test9 interface10 elemental function callee(arg1)11 integer, intent(in), optional :: arg112 integer :: fun13 end function callee14 end interface15 integer :: arr(2)16 print *, callee(arr)17end subroutine test18! The PRINT statement must be lowered into a ranked print:19! CHECK: fir.call @_FortranAioOutputDescriptor20