}
+/* Return a reference to the span field of the array descriptor DESC. */
+
static tree
-gfc_conv_descriptor_span (tree desc)
+conv_descriptor_span (tree desc)
{
tree field = gfc_get_descriptor_field (desc, SPAN_FIELD);
gcc_assert (TREE_TYPE (field) == gfc_array_index_type);
return field;
}
+/* Return the span value of the array descriptor DESC. */
+
tree
gfc_conv_descriptor_span_get (tree desc)
{
- return gfc_conv_descriptor_span (desc);
+ return conv_descriptor_span (desc);
}
+/* Add code to BLOCK assigning VALUE to the span field of the array descriptor
+ DESC. */
+
void
gfc_conv_descriptor_span_set (stmtblock_t *block, tree desc, tree value)
{
- tree t = gfc_conv_descriptor_span (desc);
+ tree t = conv_descriptor_span (desc);
gfc_add_modify (block, t, fold_convert (TREE_TYPE (t), value));
}