* breakpoint.c, breakpoint.h (breakpoint_init_inferior): New function
[deliverable/binutils-gdb.git] / gdb / m2-exp.y
index c1d6e70fdcfdeca0cb2c645eca1c85cfba3f403b..ee6799cea45393660a838e0eb02ebbaf342a2346 100644 (file)
@@ -58,16 +58,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
 #define        yyerror m2_error
 #define        yylval  m2_lval
 #define        yychar  m2_char
-#define        yycheck m2_yycheck
 #define        yydebug m2_debug
-#define        yydefred m2_yydefred
-#define        yydgoto m2_yydgoto
-#define        yygindex m2_yygindex
-#define        yylen   m2_yylen
-#define        yylhs   m2_yylhs
-#define        yyrindex m2_yyrindex
-#define        yysccsid m2_yysccsid
-#define        yysindex m2_yysindex
 #define        yypact  m2_pact
 #define        yyr1    m2_r1
 #define        yyr2    m2_r2
@@ -81,15 +72,10 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
 #define        yyps    m2_ps
 #define        yypv    m2_pv
 #define        yys     m2_s
-#define        yyss    m2_yyss
-#define        yyssp   m2_yyssp
 #define        yy_yys  m2_yys
 #define        yystate m2_state
-#define        yytable m2_yytable
 #define        yytmp   m2_tmp
 #define        yyv     m2_v
-#define        yyvs    m2_vs
-#define        yyvss   m2_vss
 #define        yy_yyv  m2_yyv
 #define        yyval   m2_val
 #define        yylloc  m2_lloc
@@ -573,6 +559,7 @@ fblock      :       block COLONCOLON BLOCKNAME
 /* Useful for assigning to PROCEDURE variables */
 variable:      fblock
                        { write_exp_elt_opcode(OP_VAR_VALUE);
+                         write_exp_elt_block (NULL);
                          write_exp_elt_sym ($1);
                          write_exp_elt_opcode (OP_VAR_VALUE); }
        ;
@@ -594,6 +581,8 @@ variable:   block COLONCOLON NAME
                                   copy_name ($3));
 
                          write_exp_elt_opcode (OP_VAR_VALUE);
+                         /* block_found is set by lookup_symbol.  */
+                         write_exp_elt_block (block_found);
                          write_exp_elt_sym (sym);
                          write_exp_elt_opcode (OP_VAR_VALUE); }
        ;
@@ -617,7 +606,10 @@ variable:  NAME
                                case LOC_LOCAL:
                                case LOC_REF_ARG:
                                case LOC_REGPARM:
+                               case LOC_REGPARM_ADDR:
                                case LOC_LOCAL_ARG:
+                               case LOC_BASEREG:
+                               case LOC_BASEREG_ARG:
                                  if (innermost_block == 0 ||
                                      contained_in (block_found,
                                                    innermost_block))
@@ -637,6 +629,10 @@ variable:  NAME
                                  break;
                                }
                              write_exp_elt_opcode (OP_VAR_VALUE);
+                             /* We want to use the selected frame, not
+                                another more inner frame which happens to
+                                be in the same block.  */
+                             write_exp_elt_block (NULL);
                              write_exp_elt_sym (sym);
                              write_exp_elt_opcode (OP_VAR_VALUE);
                            }
@@ -650,7 +646,7 @@ variable:   NAME
                              if (msymbol != NULL)
                                {
                                  write_exp_elt_opcode (OP_LONG);
-                                 write_exp_elt_type (builtin_type_int);
+                                 write_exp_elt_type (builtin_type_long);
                                  write_exp_elt_longcst ((LONGEST) SYMBOL_VALUE_ADDRESS (msymbol));
                                  write_exp_elt_opcode (OP_LONG);
                                  write_exp_elt_opcode (UNOP_MEMVAL);
@@ -1124,10 +1120,14 @@ yylex ()
        case LOC_ARG:
        case LOC_REF_ARG:
        case LOC_REGPARM:
+       case LOC_REGPARM_ADDR:
        case LOC_LOCAL:
        case LOC_LOCAL_ARG:
+       case LOC_BASEREG:
+       case LOC_BASEREG_ARG:
        case LOC_CONST:
        case LOC_CONST_BYTES:
+       case LOC_OPTIMIZED_OUT:
          return NAME;
 
        case LOC_TYPEDEF:
This page took 0.023466 seconds and 4 git commands to generate.