Work around for deref issues (least impact solution taken, even if issues remain).

This commit is contained in:
Eric Pouech 2000-12-01 20:45:24 +00:00 committed by Alexandre Julliard
parent aa838cb236
commit 52d10c9022

View file

@ -607,7 +607,20 @@ DBG_VALUE DEBUG_EvalExpr(struct expr * exp)
exp->un.unop.result = ~VAL(exp1);
break;
case EXP_OP_DEREF:
rtn.cookie = exp1.cookie;
/* FIXME: this is currently buggy.
* there is no way to tell were the deref:ed value is...
* for example:
* x is a pointer to struct s, x being on the stack
* => exp1 is target, result is target
* x is a pointer to struct s, x being optimized into a reg
* => exp1 is host, result is target
* x is a pointer to internal variable x
* => exp1 is host, result is host
* so we force DV_TARGET, because dereferencing pointers to
* internal variables is very unlikely. a correct fix would be
* rather large.
*/
rtn.cookie = DV_TARGET;
rtn.addr.off = (unsigned int) DEBUG_TypeDerefPointer(&exp1, &rtn.type);
if (!rtn.type)
{