Expansion the semanics of NamedExpression #711
Replies: 1 comment
-
I'm having a hard time following what you're asking. Why are there HierarchicalReferenceExpressions in your example with cover points? How does this relate to assertion declarations? The suggestion to have a NamedAssertionPortExpression doesn't make sense to me because assertion ports are not referenced in expressions, they are instead expanded inline like a macro argument would be (the LRM requires it be done this way because it can subtly change the semantics of the resulting expression). My suggestion in the previous discussion was to change just the assertion port case where we are fake-instantiating a sequence or property that is otherwise unused in the design -- in that case the ports, instead of being invalid expressions pointing to nothing, can instead be an invalid expression pointing to something that can hold the assertion port symbol. The HierarchicalReferenceExpression already exists so I figured that could be used. This would just be for convenience of people using the API, it would not otherwise affect any behavior. |
Beta Was this translation helpful? Give feedback.
-
Hi, Mike... I met another issue about reference issue.
Here is another case.
When I visit
CoverCrossSymbol
, I found threeNamedValueExpression
expressions,color
,pixel_hue
,pixel_offset
But I need to find its related
CoverpointSymbol
, it is simple in this case.But if I rewrite to
it fails due to two
CoverpointSymbol
owns the sameVariableSymbol
But if relax the expression, let it be
color
,Hue
,Offset
, it seems more elegant.The problem is only 'NamedValueExpression
exist. According last discussion, you suggest use
HierarchicalReferenceExpression `.The code would become
It feels ugly.
I tried to use another method is extend it.
So my visitor becomes
Do you think it is a good idea?
Beta Was this translation helpful? Give feedback.
All reactions