From a81306122a83ef8067245c6b49d0c2a03add63e4 Mon Sep 17 00:00:00 2001 From: Tobias Burnus Date: Sat, 21 Jul 2012 17:37:46 +0200 Subject: [PATCH] iso-c-binding.def (C_PTRDIFF_T): New TS29113 parameter. 2012-07-21 Tobias Burnus * iso-c-binding.def (C_PTRDIFF_T): New TS29113 parameter. * intrinsic.texi (ISO_C_BINDING): Document it. From-SVN: r189746 --- gcc/fortran/ChangeLog | 5 +++++ gcc/fortran/intrinsic.texi | 11 ++++++----- gcc/fortran/iso-c-binding.def | 2 ++ 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index b388efc22c58..33b241f3c290 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2012-07-21 Tobias Burnus + + * iso-c-binding.def (C_PTRDIFF_T): New TS29113 parameter. + * intrinsic.texi (ISO_C_BINDING): Document it. + 2012-07-21 Tobias Burnus PR fortran/48820 diff --git a/gcc/fortran/intrinsic.texi b/gcc/fortran/intrinsic.texi index 9bc36d7d4153..47a9feed68c1 100644 --- a/gcc/fortran/intrinsic.texi +++ b/gcc/fortran/intrinsic.texi @@ -13029,11 +13029,11 @@ The @code{ISO_C_BINDING} module provides the following named constants of type default integer, which can be used as KIND type parameters. In addition to the integer named constants required by the Fortran 2003 -standard, GNU Fortran provides as an extension named constants for the -128-bit integer types supported by the C compiler: @code{C_INT128_T, -C_INT_LEAST128_T, C_INT_FAST128_T}. Furthermore, if @code{__float} is -supported in C, the named constants @code{C_FLOAT128, C_FLOAT128_COMPLEX} -are defined. +standard and @code{C_PTRDIFF_T} of TS 29113, GNU Fortran provides as an +extension named constants for the 128-bit integer types supported by the +C compiler: @code{C_INT128_T, C_INT_LEAST128_T, C_INT_FAST128_T}. +Furthermore, if @code{__float128} is supported in C, the named constants +@code{C_FLOAT128, C_FLOAT128_COMPLEX} are defined. @multitable @columnfractions .15 .35 .35 .35 @item Fortran Type @tab Named constant @tab C type @tab Extension @@ -13060,6 +13060,7 @@ are defined. @item @code{INTEGER}@tab @code{C_INT_FAST128_T} @tab @code{int_fast128_t} @tab Ext. @item @code{INTEGER}@tab @code{C_INTMAX_T} @tab @code{intmax_t} @item @code{INTEGER}@tab @code{C_INTPTR_T} @tab @code{intptr_t} +@item @code{INTEGER}@tab @code{C_PTRDIFF_T} @tab @code{intptr_t} @tab TS 29113 @item @code{REAL} @tab @code{C_FLOAT} @tab @code{float} @item @code{REAL} @tab @code{C_DOUBLE} @tab @code{double} @item @code{REAL} @tab @code{C_LONG_DOUBLE} @tab @code{long double} diff --git a/gcc/fortran/iso-c-binding.def b/gcc/fortran/iso-c-binding.def index f8673b963c89..66712ad0d307 100644 --- a/gcc/fortran/iso-c-binding.def +++ b/gcc/fortran/iso-c-binding.def @@ -61,6 +61,8 @@ NAMED_INTCST (ISOCBINDING_INTMAX_T, "c_intmax_t", \ get_int_kind_from_name (INTMAX_TYPE), GFC_STD_F2003) NAMED_INTCST (ISOCBINDING_INTPTR_T, "c_intptr_t", \ get_int_kind_from_name (INTPTR_TYPE), GFC_STD_F2003) +NAMED_INTCST (ISOCBINDING_PTRDIFF_T, "c_ptrdiff_t", \ + get_int_kind_from_name (PTRDIFF_TYPE), GFC_STD_F2008_TS) NAMED_INTCST (ISOCBINDING_SIZE_T, "c_size_t", \ gfc_index_integer_kind, GFC_STD_F2003) NAMED_INTCST (ISOCBINDING_SIGNED_CHAR, "c_signed_char", \ -- 2.39.5