Share DLL code between gdb and gdbserver
[deliverable/binutils-gdb.git] / gdb / f-exp.y
index dcc28b8e600567803c38c37db92dedcd2e98af50..6608831a9a53807692f0225d185a30b8644363c9 100644 (file)
@@ -333,6 +333,9 @@ exp :       UNOP_INTRINSIC '(' exp ')'
                            case UNOP_FORTRAN_SHAPE:
                              pstate->wrap<fortran_array_shape_operation> ();
                              break;
+                           case UNOP_FORTRAN_LOC:
+                             pstate->wrap<fortran_loc_operation> ();
+                             break;
                            default:
                              gdb_assert_not_reached ("unhandled intrinsic");
                            }
@@ -489,7 +492,7 @@ exp :       '(' type ')' exp  %prec UNARY
 
 exp     :       exp '%' name
                        {
-                         pstate->push_new<structop_operation>
+                         pstate->push_new<fortran_structop_operation>
                            (pstate->pop (), copy_name ($3));
                        }
        ;
@@ -497,8 +500,8 @@ exp     :       exp '%' name
 exp     :       exp '%' name COMPLETE
                        {
                          structop_base_operation *op
-                           = new structop_operation (pstate->pop (),
-                                                     copy_name ($3));
+                           = new fortran_structop_operation (pstate->pop (),
+                                                             copy_name ($3));
                          pstate->mark_struct_expression (op);
                          pstate->push (operation_up (op));
                        }
@@ -507,7 +510,8 @@ exp     :       exp '%' name COMPLETE
 exp     :       exp '%' COMPLETE
                        {
                          structop_base_operation *op
-                           = new structop_operation (pstate->pop (), "");
+                           = new fortran_structop_operation (pstate->pop (),
+                                                             "");
                          pstate->mark_struct_expression (op);
                          pstate->push (operation_up (op));
                        }
@@ -1155,6 +1159,7 @@ static const struct token f77_keywords[] =
   { "rank", UNOP_INTRINSIC, UNOP_FORTRAN_RANK, false },
   { "size", UNOP_OR_BINOP_INTRINSIC, FORTRAN_ARRAY_SIZE, false },
   { "shape", UNOP_INTRINSIC, UNOP_FORTRAN_SHAPE, false },
+  { "loc", UNOP_INTRINSIC, UNOP_FORTRAN_LOC, false },
 };
 
 /* Implementation of a dynamically expandable buffer for processing input
This page took 0.049859 seconds and 4 git commands to generate.