]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libgfortran/intrinsics/dtime.c
re PR fortran/37577 ([meta-bug] change internal array descriptor format for better...
[thirdparty/gcc.git] / libgfortran / intrinsics / dtime.c
index 40028a689c20d27834f56bd22a4c3b5650128cb8..4b7000b446602b5d633372f3777d22bf1075a60e 100644 (file)
@@ -42,7 +42,7 @@ dtime_sub (gfc_array_r4 *t, GFC_REAL_4 *result)
   GFC_REAL_4 *tp;
   long user_sec, user_usec, system_sec, system_usec;
 
-  if (((t->dim[0].ubound + 1 - t->dim[0].lbound)) < 2)
+  if (((GFC_DESCRIPTOR_EXTENT(t,0))) < 2)
     runtime_error ("Insufficient number of elements in TARRAY.");
 
   __gthread_mutex_lock (&dtime_update_lock);
@@ -62,7 +62,7 @@ dtime_sub (gfc_array_r4 *t, GFC_REAL_4 *result)
   tp = t->data;
 
   *tp = tu;
-  tp += t->dim[0].stride;
+  tp += GFC_DESCRIPTOR_STRIDE(t,0);
   *tp = ts;
   *result = tt;
   __gthread_mutex_unlock (&dtime_update_lock);