(fold_unary_intrinsic): ... this.
(gfc_extend_expr): Adjust caller.
(gfc_match_generic_spec): Likewise. Initialize *op to INTRINSIC_NONE
to avoid warnings.
* expr.c (gfc_simplify_expr): Initialize start and end before calling
gfc_extract_int.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@148366
138bc75d-0d04-0410-961f-
82ee72b054a4
+2009-06-11 Jakub Jelinek <jakub@redhat.com>
+
+ * interface.c (fold_unary): Rename to...
+ (fold_unary_intrinsic): ... this.
+ (gfc_extend_expr): Adjust caller.
+ (gfc_match_generic_spec): Likewise. Initialize *op to INTRINSIC_NONE
+ to avoid warnings.
+ * expr.c (gfc_simplify_expr): Initialize start and end before calling
+ gfc_extract_int.
+
2009-06-10 Dave Korn <dave.korn.cygwin@gmail.com>
* trans-decl.c (create_main_function): Don't build main decl twice.
gfc_char_t *s;
int start, end;
+ start = 0;
if (p->ref && p->ref->u.ss.start)
{
gfc_extract_int (p->ref->u.ss.start, &start);
start--; /* Convert from one-based to zero-based. */
}
- else
- start = 0;
+ end = p->value.character.length;
if (p->ref && p->ref->u.ss.end)
gfc_extract_int (p->ref->u.ss.end, &end);
- else
- end = p->value.character.length;
s = gfc_get_wide_string (end - start + 2);
memcpy (s, p->value.character.string + start,
minus respectively, leaving the rest unchanged. */
static gfc_intrinsic_op
-fold_unary (gfc_intrinsic_op op)
+fold_unary_intrinsic (gfc_intrinsic_op op)
{
switch (op)
{
if (gfc_match (" operator ( %o )", &i) == MATCH_YES)
{ /* Operator i/f */
*type = INTERFACE_INTRINSIC_OP;
- *op = fold_unary (i);
+ *op = fold_unary_intrinsic (i);
return MATCH_YES;
}
+ *op = INTRINSIC_NONE;
if (gfc_match (" operator ( ") == MATCH_YES)
{
m = gfc_match_defined_op_name (buffer, 1);
actual->next->expr = e->value.op.op2;
}
- i = fold_unary (e->value.op.op);
+ i = fold_unary_intrinsic (e->value.op.op);
if (i == INTRINSIC_USER)
{