Remove completion menu entries from super concept

Hey,

In my language I reuse the StatementList concept by derive my own concept from it. I do the same with Type and Statement.
But unfortunately the editor suggest in the completion menu LocalVariableDeclarationStatements (which are not part of my language) for all my types.
My own StatementList can only contain statements of my own subconcept and I've also tried to forbid other statements than this by constraints. This just leads to error messages after selecting the entries in the completion menu but does not remove the entries.
Is there any way to override the menu of the superconcept?

And I've got just another, mostly unrelated question: What's the meaning of the return small part function in wrapper actions?
5 comments
In MPS2.5 you can import sub-language without importing the language extended by this sub-language. As a result you should be able to create instances of concepts from sub-language and should not be able to create instances of concepts from super- one.
0
Since I want to reuse some statements and expressions from baselanguage I must import this language. Isn't there a way to explicitly remove elements from the menus?

And I still have no clue what this return small part function can be used for.

Btw: Amazing response times in this thread ;)
0
Right now you can not specify that you are extending language, but you'd like to suppress all actions provided by this language.

For now I can suggest you to try using remove* actions inside side transform actions & node substitute actions root nodes of actions aspect of your language.

Trying to make response time better. ;-)
0
Oh dear, my response time is still very bad... This problem has had no high priority for me.
The hint to the side transform actions helped me very much. I've just tried to remove node substitution actions, but, of course, especially the DotExpression is inserted by a side transform action.
Many thanks for your help!
0
return small part: Should be called "set focus on wrapped node". A node substitution action returns the node on that the editor should put the caret, after the action is executed. Wrapping a node can more generally be seen as inserting one subtree into another. The wrapped node is the smaller part of the resulting tree.
0

Please sign in to leave a comment.