Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] purpose of EvalID?

One could probably unify the two evaluation objects. As it is the EvalBinding is used for the simpler cases. EvalID is needed (off the top of my head), when the name lookup or the ambiguity resolution needs to be deferred to the point of instantiation.
EvalID.instantiate() should instantiate the arguments and do the name/lookup plus overload resolution.

-----Original Message-----
From: cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Nathan Ridge
Sent: Sunday, December 02, 2012 10:58
To: CDT Mailing List
Subject: [cdt-dev] purpose of EvalID?


I am trying to fix a bug involving dependent expressions [1], but I do not fully understand the CPPEvaluation class hierarchy.

In particular, I am wondering what is the purpose of EvalID? It seems to be created as the evaluation of a CPPASTIdExpression, but since an id expression is an expression that names something, how is this different from an EvalBinding for the binding that is being named?

In the case I am investigating, an EvalID is being created for an id expression that names a template function. The arguments to the function are dependent, so the binding being named is a CPPDeferredFunction. As a result, EvalID.create() creates an EvalID rather than an EvalBinding. Later, when the enclosing template is instantiated, EvalID.instantiate() does nothing, leaving the evaluation dependent when it shouldn't be any more.

How should this be handled?



cdt-dev mailing list

Back to the top