Re: [PROPOSAL]new operator ?=

2016-11-23 Thread Marcin Erdmann
Jochen Theodorou wrote > So for me a new operator makes more sense. But frankly... > >> def foo(x) { >> return x ?: "empty" >> } > > or even > >> def foo(x) { >> x = x ?: "empty" >> return x >> } > > vs. > >> def foo(x) { >> x ?= "empty" >> return x >> } > > Is that really worth it?

Re: Elvis Assignment for Groovy 3

2016-12-03 Thread Marcin Erdmann
Awesome, thanks for implementing it Daniel. On Sat, Dec 3, 2016 at 7:59 AM, Daniel Sun wrote: > Hi all, > >The new parser "Parrot" supports Elvis Assignment(i.e. ?=) now. > Here > are some examples: > > def a = 2 > a ?= 1 > assert a == 2 > > a = null > a ?= 1 > a

Re: Default Method for Groovy 3

2016-12-08 Thread Marcin Erdmann
That's great news. Not being able to use default interface methods, especially when working with libraries using them in Java code, felt limiting. On Thu, 8 Dec 2016 at 17:40, Daniel Sun wrote: > Hi all, > > > > The new parser(Parrot) supports default method now. You can find > > the ne

Re: SimpleHTTPServer for Groovy 3( Maybe Groovy 2.5.0? )

2016-12-14 Thread Marcin Erdmann
-1 from me as well, fells more like a lib feature than a language feature. I agree with other folks that it is bloating the language for quite a narrow usecase. On Wed, 14 Dec 2016 at 12:39, Sergei Egorov wrote: > Hi Daniel, > > To be honest, I don't like it, -1 from me. > > Why? Because we alr

Re: SAM type closure coercion

2017-01-19 Thread Marcin Erdmann
Was that the one case when moaning about other people's work is not frowned upon? Damn, I wish I knew, I would unleash my moaning in public! But seriously, this limitation is very annoying when you work with Ratpack in Groovy. I have moved towards more type safe coding recently and when I learned

Re: The order of modifiers and annotations

2017-01-19 Thread Marcin Erdmann
Sorry for stealing the thread, but there is one annoying thing that relates to parsing modifiers in Groovy. Is there any chance to fix modifier being mandatory for methods with generic signatures in Parrot? I.e. this is now invalid: T foo(T bar) and has to be written like this to be parsed: pub

Re: The order of modifiers and annotations

2017-01-20 Thread Marcin Erdmann
Awesome! On Thu, Jan 19, 2017 at 11:01 AM, Daniel Sun wrote: > I verified that the new parser Parrot does not have the issue( GROOVY-4757 > ), the following test > case was added in the parrot branch. And I'll resolve the JIRA issue later. > >

Re: [CANCEL][VOTE] Release Apache Groovy 2.4.10

2017-03-14 Thread Marcin Erdmann
Following instructions and reading documentation instead of relying on one's assumptions? Why on earth would you do that? ;) On Tue, Mar 14, 2017 at 12:49 PM, Guillaume Laforge wrote: > Last words... > Following the build instructions properly, and use "gradle" to let it > create the wrapper (ra

Re: [ANNOUNCE] Apache Groovy 2.5.0-alpha-1 Released

2017-05-23 Thread Marcin Erdmann
FWIW, I've finally managed to get some time to check if Geb will build and its tests pass with this version. Hopefully this is the right forum to report back on how it went. I was particularly interested in that version because it contains an improvement I contributed which allows me to remove sev

Re: Build failing

2017-06-17 Thread Marcin Erdmann
I'm now trying to give you the strength to do so with the power of my mind because I don't know any other way! ;) Good luck, you'll need it. On Sat, 17 Jun 2017 at 08:44, Cédric Champeau wrote: > Yes, there are apparently quite a few glitches after the upgrade. > > Dear community, please give m

Re: How to find out the names of variables used in a groovy expression

2017-11-26 Thread Marcin Erdmann
Wouldn't it be easier for you then to implement a class which extends groovy.lang.Binding which lazy evaluates your default variables and use that as your script binding instead? On Sun, Nov 26, 2017 at 6:26 PM, bayareagreg wrote: > All right, let me explain why I need this. > In my product, we

Re: CC and build revision

2017-12-16 Thread Marcin Erdmann
I'd be happy to help with an item or two but knowing what exactly needs doing would definitely help me to make a decision in really committing myself to it. On Fri, Dec 15, 2017 at 7:24 PM, Russel Winder wrote: > Hi, > > > I second mg's sentiments: a high level list of items to complete for the

Re: About adding DGM startsWith(String...) and endsWith(String...)

2017-12-31 Thread Marcin Erdmann
My only thought is that it can also be achieved using =~ and a regular expression, it.file.name =~ /^(?:asm|antlr|antlr4)-/ On Sun, Dec 31, 2017 at 12:24 PM, Daniel.Sun wrote: > Hi all, > > I am going to add startsWith(String...) and endsWith(String...) for > java.lang.String(i.e. if and

Re: [ANNOUNCE] Apache Groovy 2.5.0-rc-1 released

2018-04-09 Thread Marcin Erdmann
Paul, I'm having a go at giving this release a spin by updating Geb's build to use it but unfortunately I'm not having any luck with trying to use the groovy-all artifact. I understand from the earlier thread about updates to the build on the dev list that the jar for that artifact is not publishe

Re: [ANNOUNCE] Apache Groovy 2.5.0-rc-1 released

2018-04-10 Thread Marcin Erdmann
, 2018 at 8:20 AM, Cédric Champeau wrote: > There's a bug in the published pom: it says zip > instead of pom. We should fix this, thanks for the > report! > > > > 2018-04-09 23:15 GMT+02:00 Marcin Erdmann : > >> Paul, >> >> I'm having a go at givi

Re: [ANNOUNCE] Apache Groovy 2.5.0-rc-1 released

2018-04-10 Thread Marcin Erdmann
https://issues.apache.org/jira/browse/GROOVY-8541 I took the liberty to set priority and fix version. On Tue, Apr 10, 2018 at 10:55 AM, Cédric Champeau wrote: > > > 2018-04-10 11:52 GMT+02:00 Marcin Erdmann : > >> Yeah, I've noticed the zip packaging in pom but wa

Re: Troubles with IDEA setup

2018-05-23 Thread Marcin Erdmann
An even less constructive response - you are very wrong, IMHO. :) I always use Gradle's idea plugin on my projects because it gives me far better control on how the IntelliJ project looks like and what it does then if I "natively imported" it, as Cedric calls it. I find native imports very selecti

Re: Troubles with IDEA setup

2018-05-23 Thread Marcin Erdmann
Cedric, I've just pulled master then I got rid of all idea config files and build direcotries to start with a clean state: rm groovy.i* find . -name "*.iml" -type f | xargs rm -f ./gradlew clean Then I run the same command as you: ./gradlew jar idea --rerun-tasks Finally I opened the project in

Re: DGM wildcards

2018-12-08 Thread Marcin Erdmann
If there is willingness to accept contributions in that area then I'd be happy to give it a shot. I would be much happier myself if the tooling, especially IntelliJ, had a better chance of understanding the types, especially when closures are used as arguments, for DGM methods. Marcin On Sat, Dec

Re: DGM wildcards

2018-12-09 Thread Marcin Erdmann
haps even Intellij) but has no improvement for the type > checker until the generics issue is resolved, or whether it now actually > works fully. > > Cheers, Paul. > > > On Sat, Dec 8, 2018 at 10:48 PM Marcin Erdmann > wrote: > >> If there is willingness to accept

Re: [PROPOSAL]About creating open collective for Groovy programming language in the name of Groovy Community

2019-01-10 Thread Marcin Erdmann
Given that I have no association with ASF nor am I a PMC member or a committer I would be happy to take ownership of running the collective if that helps. Of course only after we figure out how to actually set it up and run it without violating anything. Marcin On Thu, Jan 10, 2019 at 8:20 AM Céd

Re: [PROPOSAL]About creating open collective for Groovy programming language in the name of Groovy Community

2019-02-07 Thread Marcin Erdmann
On Tue, Feb 5, 2019 at 3:02 PM Roman Shaposhnik wrote: > On a side of somebody who may consider donating -- I'd also like to see a > clearly > articulated statement of how the money received will be spent. > > I'd be interested in that too. Cheers, Marcin