diff options
Diffstat (limited to 'flang/test/Parser/compiler-directives.f90')
| -rw-r--r-- | flang/test/Parser/compiler-directives.f90 | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/flang/test/Parser/compiler-directives.f90 b/flang/test/Parser/compiler-directives.f90 index 04d22ff..b2fe4663 100644 --- a/flang/test/Parser/compiler-directives.f90 +++ b/flang/test/Parser/compiler-directives.f90 @@ -72,3 +72,27 @@ subroutine no_vector do i=1,10 enddo end subroutine + +subroutine inline + integer :: a + !dir$ forceinline + ! CHECK: !DIR$ FORCEINLINE + a = f(2) + + !dir$ inline + ! CHECK: !DIR$ INLINE + call g() + + !dir$ noinline + ! CHECK: !DIR$ NOINLINE + call g() + + contains + function f(x) + integer :: x + f = x**2 + end function + + subroutine g() + end subroutine +end subroutine |
