[rules-dev] Drools syntax diagrams - redrawn

Bruno Unna bruno.unna at gmail.com
Thu Sep 23 03:31:18 EDT 2010


FWIW: in Perl, there are both operators as well (|| and 'or').  
However, they are *not* exactly the same. Although they can be used in  
any context to render a boolean expression, their priority makes the  
difference. Taken from official documentation (http://bit.ly/dgw4GT):

> Binary "or" returns the logical disjunction of the two surrounding  
> expressions. It's equivalent to || except for the very low  
> precedence. This makes it useful for control flow.


Nonetheless, it must be taken into account that the distinction makes  
sense for a Perl programmer. For a rules-writing guy (or girl) perhaps  
the distinction is extremely obscure.

Regards.


On 22/09/2010, at 18:20, Wolfgang Laun wrote:

> See my remarks inline.
>
> On 22 September 2010 17:03, Mark Proctor <mproctor at codehaus.org>  
> wrote:
>  So things that are doing are:
>
> Single binding on 'or'
> $binding : ( Pattern() || Pattern() )
>
> We are thinking of only allowing 'or' between patterns and not  
> allowing users to mix and match 'or' and '||'.  Inside of patterns  
> '||' is the only connective allowed and will remain so.
>
> OK, a clear distinction avoids confusion.

--
Bruno Unna
Public key available

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-dev/attachments/20100923/77e32c0c/attachment.html 


More information about the rules-dev mailing list