(simply use DEREF unary op)
Signed-off-by: Eric Pouech eric.pouech@gmail.com
--- programs/winedbg/dbg.y | 2 +- programs/winedbg/expr.c | 5 ----- programs/winedbg/expr.h | 1 - 3 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/programs/winedbg/dbg.y b/programs/winedbg/dbg.y index b10f50a3d6a..d14ae1c399a 100644 --- a/programs/winedbg/dbg.y +++ b/programs/winedbg/dbg.y @@ -411,7 +411,7 @@ lvalue: | lvalue OP_DRF tIDENTIFIER { $$ = expr_alloc_pstruct($1, $3); } | lvalue '.' tIDENTIFIER { $$ = expr_alloc_struct($1, $3); } | lvalue '[' expr ']' { $$ = expr_alloc_binary_op(EXP_OP_ARR, $1, $3); } - | '*' expr { $$ = expr_alloc_unary_op(EXP_OP_FORCE_DEREF, $2); } + | '*' expr { $$ = expr_alloc_unary_op(EXP_OP_DEREF, $2); } ;
%% diff --git a/programs/winedbg/expr.c b/programs/winedbg/expr.c index 7a7c2013578..0b5b1c544f3 100644 --- a/programs/winedbg/expr.c +++ b/programs/winedbg/expr.c @@ -556,11 +556,6 @@ struct dbg_lvalue expr_eval(struct expr* exp) if (!types_array_index(&exp1, 0, &rtn)) RaiseException(DEBUG_STATUS_BAD_TYPE, 0, 0, NULL); break; - case EXP_OP_FORCE_DEREF: - rtn = exp1; - if (exp1.in_debuggee) - dbg_read_memory(memory_to_linear_addr(&exp1.addr), &rtn.addr.Offset, sizeof(rtn.addr.Offset)); - break; case EXP_OP_ADDR: /* only do it on linear addresses */ if (exp1.addr.Mode != AddrModeFlat) diff --git a/programs/winedbg/expr.h b/programs/winedbg/expr.h index 295543ec292..24303a4a562 100644 --- a/programs/winedbg/expr.h +++ b/programs/winedbg/expr.h @@ -41,4 +41,3 @@ #define EXP_OP_ADDR 0x27 #define EXP_OP_ARR 0x28 #define EXP_OP_SEG 0x29 -#define EXP_OP_FORCE_DEREF 0x2a