`/* Implementation of the SHAPE intrinsic
- Copyright 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2006 Free Software Foundation, Inc.
Contributed by Paul Brook <paul@nowt.org>
This file is part of the GNU Fortran 95 runtime library (libgfortran).
#include "libgfortran.h"'
include(iparm.m4)dnl
-extern void shape_`'rtype_kind (rtype * ret, const rtype * array);
-export_proto(shape_`'rtype_kind);
+`#if defined (HAVE_'rtype_name`)
+
+extern void shape_'rtype_kind` ('rtype` * const restrict ret,
+ const 'rtype` * const restrict array);
+export_proto(shape_'rtype_kind`);
void
-shape_`'rtype_kind (rtype * ret, const rtype * array)
+shape_'rtype_kind` ('rtype` * const restrict ret,
+ const 'rtype` * const restrict array)
{
int n;
index_type stride;
stride = ret->dim[0].stride;
- if (stride == 0)
- stride = 1;
for (n = 0; n < GFC_DESCRIPTOR_RANK (array); n++)
{
array->dim[n].ubound + 1 - array->dim[n].lbound;
}
}
+
+#endif'