RefNode becomes <abstract concept> in editor Follow
Hi,
I'm trying to create an editor for a simple struct-like DSL, but when I try to enter my Type in my editor, the text disappears and is replaced with the grey text <abstract concept>. I do see all of my types listed in the code assist popup (not sure of the correct terminology for that), but even when I select one of the entries, I end up with the same <abstract concept> result. Here's a small sample of what the language looks like:
record RECT
Left : Byte
Top : Byte
Right : Byte
Bottom : Byte
end record
I've created a Type concept and all primitive types derive from that concept. I refer to the entries in the body of the record as fields and I've defined them like so:
properties:
name : string
children:
Type type 1 specializes: <none>
and my field editor looks like:
[> { name } : % type % <]
I'm sure I'm missing something simple here. I probably could extend baseLanguage to get some of this functionality for free, but I'd prefer to build this language from scratch to get a better understanding of all the concepts.
Thanks!
Kevin
Please sign in to leave a comment.
Hello, Kevin.
When you put the curson on <abstract concept> and invoke the completion menu which items do you see there?
Have you provided editors for all of your types.
P.S. You can attach you project here and I will take a look at it.
Regards,
Konstantin
Hi Konstantin,
Ahh, that was the hint I needed. To answer your earlier question, I am seeing all of my primitive types and their aliases in the completion menu. I noticed when I looked at my test model that I did see the Type I had selected, but the editor still showed <abstract concept>. So, I added an editor to Type from which all my primitives derive, and that resolved my issue.
I'm simply showing the Type's concept name and I'm doing that via *model access*. Is that the proper way to do that?
Thanks!
Kevin
Hello, Kevin,
Yes, it's absolutely ok. There's another way you can do it. Take a look at BinaryOperation's editor from the base language.
Regards,
Konstantin
I also have this effect that one gets a completion menu where the concept is listed as it should, but when selecting it one gets
<abstract concept>
instead of the defined editor for this concept. So in my case there is an editor but I still get this behaviour.
What other reasons could there be for it?