How to check types for equality?

I have to check in my generator if two types are equal. Is there any operation for this? I've found the isSubtype expression but nothing for equality. The '==' operator does not work and there is no equals method in nodes. But I guess there must be something I've missed.
4 comments
You can use
jetbrains.mps.lang.pattern.util.MatchingUtil.matchNodes(type1, type2)
prettyPrint(); to compare two types.
0
Great, this works! Thanks!
But there should be really a list of util classes contained in MPS. I guess I could save some development and testing time...
0
Make sense! We'll discuss the possibility to create a page with the list of utility classes..
0
Or use the "matches" operator, which does the same.

matches.png
1

Please sign in to leave a comment.