aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSa Liu <saliu@gcc.gnu.org>2008-05-15 12:59:49 +0000
committerSa Liu <saliu@gcc.gnu.org>2008-05-15 12:59:49 +0000
commit96d5b5284e4a4a3b777c80899f80ae939fbb553e (patch)
tree69e78478b6511fbf5dc64a46f1b93b76ffbb1ae4
parentc129abb4070b4980936bab3e926ddc188c620960 (diff)
downloadgcc-96d5b5284e4a4a3b777c80899f80ae939fbb553e.zip
gcc-96d5b5284e4a4a3b777c80899f80ae939fbb553e.tar.gz
gcc-96d5b5284e4a4a3b777c80899f80ae939fbb553e.tar.bz2
Test int128 when -std=f2003
From-SVN: r135347
-rw-r--r--gcc/testsuite/gfortran.dg/c_kind_int128_test1.f0324
1 files changed, 24 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/c_kind_int128_test1.f03 b/gcc/testsuite/gfortran.dg/c_kind_int128_test1.f03
new file mode 100644
index 0000000..6be1ac2
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/c_kind_int128_test1.f03
@@ -0,0 +1,24 @@
+! { dg-do compile }
+! { dg-options "-std=f2003" }
+! { dg-require-effective-target fortran_integer_16 }
+!
+! Note: int_fast*_t currently not supported.
+
+subroutine c_kind_int128_1
+ use, intrinsic :: iso_c_binding
+ implicit none
+
+ integer(c_int128_t) :: a ! { dg-error "has no IMPLICIT type" }
+ integer(c_int_least128_t) :: b ! { dg-error "has no IMPLICIT type" }
+! integer(c_int_fast128_t) :: c
+
+end subroutine c_kind_int128_1
+
+subroutine c_kind_int128_2
+ use, intrinsic :: iso_c_binding
+
+ integer(c_int128_t) :: a ! { dg-error "has not been declared or is a variable" }
+ integer(c_int_least128_t) :: b ! { dg-error "has not been declared or is a variable" }
+! integer(c_int_fast128_t) :: c
+
+end subroutine c_kind_int128_2