Re: [Grammatica-devel] @Override

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: [Grammatica-devel] @Override

hilco
(I'm including both lists now to move the discussion to
grammatica-users. Please only reply on grammatica-users.)

Given that the current trunk has multiple build problems I didn't get
around to my original reason for checking out the source code. :-) So
no patches yet for @Override.

The current trunk outputs the Grammar*.java files into the root
instead of the net.percederberg.grammatica package. I was able to fix
it but I assume there was a reason to take out the package reference
so I doubt my putting it back in would be the right way forward. There
are also two unit tests that fail. I didn't look into that yet.

It looks like someone was half way through some changes and then
committed before being fully done.

Cheers,
Hilco

2009/9/20 Per Cederberg <[hidden email]>:

> ---------- Forwarded message ----------
> From: Connor Robert Prussin <[hidden email]>
> Date: Sun, Sep 20, 2009 at 18:25
> Subject: Re: [Grammatica-devel] @Override
> To: Per Cederberg <[hidden email]>
>
>
> Hey Guys-
>
> I'd be happy to take a look at the code!  I've been really busy
> lately, and have a few of Oliver's proposals to work on still; however
> I have full plans on working on those and getting them merged in.
> Hilco- if you have any patches already, I'd be happy to take a look at
> them and commit them for you.  If you want commit access, Per will
> need to set it up.
>
> I think that there is a lot that can be migrated to Java 1.6-style
> code.  I worked a bit on it, but focused mostly on new code so I
> didn't get much done.
>
> Connor
>
>
> On Sun, Sep 20, 2009 at 4:40 AM, Per Cederberg <[hidden email]> wrote:
>> Hi Hilco,
>>
>> All code contributions are gladly accepted. Haven't had time to review
>> the code myself for a long time, but Connor has been working on the
>> Grammatica codebase during the summer. Perhaps he has time to review
>> and apply any patches?
>>
>> The codegen step should create code in the package of your choice,
>> which for the parser itself has always been
>> net.percederberg.grammatica.parser I think. Or something similar.
>>
>> @Connor: Do you subscribe to this mailing list? I guess we should
>> really merge it into the normal grammatica-users list due to the low
>> traffic of both lists... Well, well.
>>
>> Cheers,
>>
>> /Per
>>
>> On Sun, Sep 20, 2009 at 04:11, Hilco Wijbenga <[hidden email]> wrote:
>>> Hi all,
>>>
>>> I wanted to see if I could add "@Override" to the generated code where
>>> necessary because Eclipse was complaining about it. So I checked out
>>> the code from Subversion but trunk doesn't build.
>>>
>>> The current build uses source="1.4" and target="1.5" but the source is
>>> 1.5 (it uses enum and generics). I also noticed some warnings that can
>>> be easily fixed (generics again).
>>>
>>> The codegen step generates code in src/java instead of
>>> src/java/net/percederberg/grammatica. I could easily fix all this and
>>> send in a patch but I don't want to step on anyone's toes or interfere
>>> with ongoing work. So I thought I'd ask first. :-)
>>>
>>> Cheers,
>>> Hilco
>>>
>>>
>>> _______________________________________________
>>> Grammatica-devel mailing list
>>> [hidden email]
>>> http://lists.nongnu.org/mailman/listinfo/grammatica-devel
>>>
>>
>


_______________________________________________
Grammatica-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/grammatica-users
Reply | Threaded
Open this post in threaded view
|

Re: Re: [Grammatica-devel] @Override

Connor Robert Prussin
Hey Wilco-

> The current trunk outputs the Grammar*.java files into the root
> instead of the net.percederberg.grammatica package. I was able to fix
> it but I assume there was a reason to take out the package reference
> so I doubt my putting it back in would be the right way forward.

That was as designed.  If you want the files to be put in a specific
package, you must use the "--javapackage" flag.  See -h documentation
for more information.

> There are also two unit tests that fail. I didn't look into that yet.

The unit tests have not been really fully written or maintained yet.
It's one of the things I wanted to look into finishing, but still
haven't been able to.  I'm still intending on cleaning it up when I
can though.

Connor


_______________________________________________
Grammatica-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/grammatica-users
Reply | Threaded
Open this post in threaded view
|

Re: Re: [Grammatica-devel] @Override

hilco
2009/9/20 Connor Robert Prussin <[hidden email]>:
>> The current trunk outputs the Grammar*.java files into the root
>> instead of the net.percederberg.grammatica package. I was able to fix
>> it but I assume there was a reason to take out the package reference
>> so I doubt my putting it back in would be the right way forward.
>
> That was as designed.  If you want the files to be put in a specific
> package, you must use the "--javapackage" flag.  See -h documentation
> for more information.

I've only used Grammatica through the Ant task and the Java package
was definitely specified. (I realize the wording above seems to
indicate that it should always go into "net.percederberg.grammatica"
but that was not my intent.)


_______________________________________________
Grammatica-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/grammatica-users
Reply | Threaded
Open this post in threaded view
|

Re: Re: [Grammatica-devel] @Override

Per Cederberg
In reply to this post by Connor Robert Prussin
Grammatica is recursive in that it uses itself to parse the .grammar
files... So there is a parser generated during the build process. That
parser is generated into the package specified by Hilco.

Cheers,

/Per

On Mon, Sep 21, 2009 at 07:13, Connor Robert Prussin <[hidden email]> wrote:

> Hey Wilco-
>
>> The current trunk outputs the Grammar*.java files into the root
>> instead of the net.percederberg.grammatica package. I was able to fix
>> it but I assume there was a reason to take out the package reference
>> so I doubt my putting it back in would be the right way forward.
>
> That was as designed.  If you want the files to be put in a specific
> package, you must use the "--javapackage" flag.  See -h documentation
> for more information.
>
>> There are also two unit tests that fail. I didn't look into that yet.
>
> The unit tests have not been really fully written or maintained yet.
> It's one of the things I wanted to look into finishing, but still
> haven't been able to.  I'm still intending on cleaning it up when I
> can though.
>
> Connor
>
>
> _______________________________________________
> Grammatica-users mailing list
> [hidden email]
> http://lists.nongnu.org/mailman/listinfo/grammatica-users
>


_______________________________________________
Grammatica-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/grammatica-users
Reply | Threaded
Open this post in threaded view
|

Re: Re: [Grammatica-devel] @Override

Connor Robert Prussin
In reply to this post by hilco
Hilco-

Can you show me exactly what you were typing and recieving?

Connor


On Mon, Sep 21, 2009 at 1:40 AM, Hilco Wijbenga
<[hidden email]> wrote:

> 2009/9/20 Connor Robert Prussin <[hidden email]>:
>>> The current trunk outputs the Grammar*.java files into the root
>>> instead of the net.percederberg.grammatica package. I was able to fix
>>> it but I assume there was a reason to take out the package reference
>>> so I doubt my putting it back in would be the right way forward.
>>
>> That was as designed.  If you want the files to be put in a specific
>> package, you must use the "--javapackage" flag.  See -h documentation
>> for more information.
>
> I've only used Grammatica through the Ant task and the Java package
> was definitely specified. (I realize the wording above seems to
> indicate that it should always go into "net.percederberg.grammatica"
> but that was not my intent.)
>
>
> _______________________________________________
> Grammatica-users mailing list
> [hidden email]
> http://lists.nongnu.org/mailman/listinfo/grammatica-users
>


_______________________________________________
Grammatica-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/grammatica-users
Reply | Threaded
Open this post in threaded view
|

Re: Re: [Grammatica-devel] @Override

hilco
:-) Just run the build. It's hard to miss.

I tried to pinpoint the problem by creating my own Ant task invocation
(in Eclipse) but the problem is easiest to reproduce by simply running
the build.

2009/9/20 Connor Robert Prussin <[hidden email]>:

> Hilco-
>
> Can you show me exactly what you were typing and recieving?
>
> Connor
>
>
> On Mon, Sep 21, 2009 at 1:40 AM, Hilco Wijbenga
> <[hidden email]> wrote:
>> 2009/9/20 Connor Robert Prussin <[hidden email]>:
>>>> The current trunk outputs the Grammar*.java files into the root
>>>> instead of the net.percederberg.grammatica package. I was able to fix
>>>> it but I assume there was a reason to take out the package reference
>>>> so I doubt my putting it back in would be the right way forward.
>>>
>>> That was as designed.  If you want the files to be put in a specific
>>> package, you must use the "--javapackage" flag.  See -h documentation
>>> for more information.
>>
>> I've only used Grammatica through the Ant task and the Java package
>> was definitely specified. (I realize the wording above seems to
>> indicate that it should always go into "net.percederberg.grammatica"
>> but that was not my intent.)
>>
>>
>> _______________________________________________
>> Grammatica-users mailing list
>> [hidden email]
>> http://lists.nongnu.org/mailman/listinfo/grammatica-users
>>
>
>
> _______________________________________________
> Grammatica-users mailing list
> [hidden email]
> http://lists.nongnu.org/mailman/listinfo/grammatica-users
>


_______________________________________________
Grammatica-users mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/grammatica-users