The ‘bagof’ operator for dynamic rules fails for static patterns:

 rules(Foo :+  "a"  -> "b");    
 <bagof-Foo> "N/A"

But returns an empty list if a dynamic pattern is used:

 a := "a";
 rules(Foo :+  a  -> "b");    
 <bagof-Foo> "N/A"   

Or even if such a pattern is used in another place in the program:

 <bagof-Foo> "N/A";
 rules(Foo :+  _ -> "b")

I think it should also return an empty list in the first case?

Submitted on 14 April 2008 at 14:37

On 27 October 2011 at 13:20 Tobi Vollebregt tagged !tvo

Log in to post comments