TODO in assignment pattern #387
|
Hi Mike, when reading code about assignment pattern , I don't quite understand the meaning of a TODO in PatternExpression.cpp, line 27: if (syntax.type) {
// TODO: allow type references hereDoes it mean |
Answered by
MikePopoloski
Mar 4, 2021
Replies: 2 comments 4 replies
|
A type reference is the result of the |
2 replies
Answer selected by
zzq0119
|
I have another question in PatternExpression.cpp, line 745 I guess it means indexExpr must be constant and the following code is illegal module M;
int index=0;
int cc[int]='{index:1};
initial $display("%d",cc[0]);
endmoduleBut I haven't find any restriction in Chapter 10 or Chapter 7 of IEEE Std 1800-2017 which requires that the item key should be constant. Will any semantic errors be here if non-constant value is used as key? |
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A type reference is the result of the
typeoperator. This is saying it should be possible to do something liketype(some_expression)'{1, 2, 3}