Page 1 of 1

Predicate not found

Posted: 27 Apr 2019 13:34
by Martin Meyer
Hello Thomas,

please have a look at this predicates from-supports-predicates from construction (in build 902):

Code: Select all

interface obj0   predicates     p : ().   end interface obj0   %===   interface obj1   predicates from obj0     p/0   end interface obj1   %===   interface obj2 supports obj1 end interface obj2   %===   interface obj3   predicates from obj2     p/0 %raises The predicate or property 'p/0' that is specified in predicates     % from/resolve/delegate section is not found in the class or interface 'obj2'   end interface obj3

Re: Predicate not found

Posted: 27 Apr 2019 20:45
by Thomas Linder Puls
predicates from must refer directly to the original declaration of the predicate. So you must write from obj0.

Re: Predicate not found

Posted: 27 Apr 2019 22:58
by Martin Meyer
Thank you for the info! In some cases it works however to not refer to the original declaration:

Code: Select all

interface obj0   predicates     p : ().   end interface obj0   %===   interface obj1   predicates from obj0     p/0   end interface obj1   %===   interface obj2   predicates from obj1     p/0   end interface obj2
I would vote for that in future versions you make it work out in all cases.

Re: Predicate not found

Posted: 28 Apr 2019 17:21
by Thomas Linder Puls
Yes, I was inaccurate. It must point to an interface that contains a relevant declaration.

Re: Predicate not found

Posted: 28 Apr 2019 21:30
by Martin Meyer
This works too:

Code: Select all

interface obj0   predicates     p : ().   end interface obj0   %===   interface obj1 supports obj0 end interface obj1   %===   interface obj2 supports obj1 end interface obj2   %===   interface obj3   predicates from obj2     p/0   end interface obj3
But that does not:

Code: Select all

interface obj0   predicates     p : ().   end interface obj0   %===   interface obj1   predicates from obj0     p/0   end interface obj1   %===   interface obj2   predicates from obj1     p/0   end interface obj2   %===   interface obj3   predicates from obj2     p/0 %raises exception   end interface obj3

Re: Predicate not found

Posted: 30 Apr 2019 8:35
by Thomas Linder Puls
Well, I guess we better look at this.