This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch, Fortran] PR35203 - reject dummies with VALUE + OPTIONAL


On Wed, Mar 26, 2008 at 9:43 PM, Tobias Schlüter
<tobias.schlueter@physik.uni-muenchen.de> wrote:
>
> Tobias Burnus wrote:
>  > Having a dummy which has VALUE and OPTIONAL attribute does not work in
>  > gfortran, but is valid Fortran 9x/200x; to be more precise: One cannot
>  > distinguish an absent argument (argument == NULL) from an argument
>  > of value 0 (argument == 0). Without VALUE this is easy: arg == NULL
>  > vs. *arg == 0.
>  >
>  > One has therefore to do the same as for character variables: A hidden
>  > argument needs to be passed.
>  >
>  > This patch takes the simple route by simply rejecting such dummies.
>  >
>  > OK for the trunk?
>
>  Please don't use gfc_error for shortcomings in the compiler.  ICEing or
>  gfc_internal_error is much more appropriate for something where the
>  compiler is at fault.

We have sorry () for this purpose (known implementation limitations).

Richard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]