Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 001DA200BB4 for ; Tue, 1 Nov 2016 15:38:09 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id F2A6E160AF7; Tue, 1 Nov 2016 14:38:09 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 1C455160AE5 for ; Tue, 1 Nov 2016 15:38:08 +0100 (CET) Received: (qmail 14847 invoked by uid 500); 1 Nov 2016 14:38:08 -0000 Mailing-List: contact dev-help@groovy.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@groovy.apache.org Delivered-To: mailing list dev@groovy.apache.org Received: (qmail 14833 invoked by uid 99); 1 Nov 2016 14:38:08 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 01 Nov 2016 14:38:07 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 888C818061A for ; Tue, 1 Nov 2016 14:38:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 5.573 X-Spam-Level: ***** X-Spam-Status: No, score=5.573 tagged_above=-999 required=6.31 tests=[FORGED_HOTMAIL_RCVD2=1.187, HTML_MESSAGE=2, KAM_UNSUB1=0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_SOFTFAIL=0.972, URIBL_BLOCKED=0.001, URI_HEX=1.313] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id cE3UfoSuTWds for ; Tue, 1 Nov 2016 14:38:03 +0000 (UTC) Received: from mbob.nabble.com (mbob.nabble.com [162.253.133.15]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id D414B5F20B for ; Tue, 1 Nov 2016 14:38:02 +0000 (UTC) Received: from static.162.255.23.22.macminivault.com (unknown [162.255.23.22]) by mbob.nabble.com (Postfix) with ESMTP id 1063334FB6A9 for ; Tue, 1 Nov 2016 07:29:51 -0700 (PDT) Date: Tue, 1 Nov 2016 07:38:01 -0700 (MST) From: "Daniel.Sun" To: dev@groovy.incubator.apache.org Message-ID: In-Reply-To: References: <1477819837808-5736394.post@n5.nabble.com> <1477822075297-5736396.post@n5.nabble.com> <5815E46B.2000909@gmx.org> Subject: Re: Custom operator for Groovy 3 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_38481_333471602.1478011081782" archived-at: Tue, 01 Nov 2016 14:38:10 -0000 ------=_Part_38481_333471602.1478011081782 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi Jochen, > "obj.hello('Daniel')" My mail client translated the generics type to html tag, which is ignored..= . The example code is about generics method call. > I expected conflicts with a.*x and a.?x, but not with an import. The lexer will try to match as many characters as possible and make tokens,= as a result, .* in the import statement is also recognized as custom opera= tor. So I use ` instead for the time being. Cheers, Daniel.Sun =E5=9C=A8 "Jochen Theodorou [via Groovy]" =EF=BC=8C2016=E5=B9=B411=E6=9C=881=E6=97=A5 =E4=B8=8B=E5=8D=8810:1= 7=E5=86=99=E9=81=93=EF=BC=9A On 01.11.2016 02:39, Daniel.Sun wrote: > Hi Jochen, > > I tried to implement custom operator based on your new idea and > found it a bit ambiguous, e.g. ".<" is ambiguous to > "obj.hello('Daniel')" this I do not understand really, unless < can be part of an identifier or an identifier can end with a dot, but the later would produce even more ambiguity problems. >, ".*" is ambiguous to "import java.util.*", etc. I expected conflicts with a.*x and a.?x, but not with an import. Makes me think the approach is maybe wrong. Where did you do the changes? Some place as for thee `? bye Jcohen ________________________________ If you reply to this email, your message will be added to the discussion be= low: http://groovy.329449.n5.nabble.com/Custom-operator-for-Groovy-3-tp5736388p5= 736441.html To unsubscribe from Custom operator for Groovy 3, click here. NAML -- View this message in context: http://groovy.329449.n5.nabble.com/Custom-ope= rator-for-Groovy-3-tp5736388p5736442.html Sent from the Groovy Dev mailing list archive at Nabble.com. ------=_Part_38481_333471602.1478011081782 Content-Type: text/html; charset=UTF8 Content-Transfer-Encoding: quoted-printable
Hi Jochen,

> "obj.hello('Daniel')" 
My mail client translated the generics type to html tag, w= hich is ignored... The example code is about generics method call.

> I expected conflicts with a.*x and a.?x, but not with= an import. 
The lexer will try to match as many characters as possible= and make tokens, as a result, .* in the import statement is also recognize= d as custom operator. So I use ` instead for the time being.

Cheers,
Daniel.Sun




=E5=9C=A8 "Jochen Theodorou [via Groovy]&qu= ot; <ml-node+[hidden email]= >=EF=BC=8C2016=E5=B9=B411=E6=9C=881=E6=97=A5 =E4=B8=8B=E5=8D=8810:17= =E5=86=99=E9=81=93=EF=BC=9A



On 01.11.2016 02:39, Daniel.Sun wrote:
> Hi Jochen,
>
>       I tried to implement custom operator based on you= r new idea and
> found it a bit ambiguous, e.g. ".<" is ambiguous to
> "obj.hello('Daniel')"

this I do not understand really, unless < can be part of an identifier <= br> or an identifier can end with a dot, but the later would produce even
more ambiguity problems.

>, ".*" is ambiguous to "import java.util.*", etc. <= br>
I expected conflicts with a.*x and a.?x, but not with an import. Makes
me think the approach is maybe wrong. Where did you do the changes? Some place as for thee `?

bye Jcohen



If you reply to this email, your message wi= ll be added to the discussion below:
http://groovy.329449.n5.nabble.com/Custom-operator-for-Groovy-3-tp5736388= p5736441.html
To unsubscribe from Custom operator for Groovy 3, click here.
NAML
=09 =09 =09

View this message in context: Re: Custom operator f= or Groovy 3
Sent from the Groovy Dev mailing list archive at Nabble.com.
------=_Part_38481_333471602.1478011081782--