Code formatting unusual

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Code formatting unusual

Thomas Hofmann

Hi,

 

I have a map which I use as interface implementation. The code is formated in an unusual way:

 

                  IPreferenceFilter filter = [

                  getMapping: { return null

                  },

                  getScopes: {

                        return [InstanceScope.SCOPE, ConfigurationScope.SCOPE]

                  }

                  ] as IPreferenceFilter

 

Should such things be mentioned here or should I open a ticket somewhere?

 

Thanks, Thomas

Reply | Threaded
Open this post in threaded view
|

Re: Code formatting unusual

Andrew Eisenberg
Hi Thomas,

I am not sure if this particular problem is included in the existing
jira issues, so could you please raise one for us and included the
code snippet?  The issue tracker is here:

http://jira.codehaus.org/browse/GRECLIPSE

Formatting and indentation are two areas that we will be focussing on
over the next little while and so your issue will be included in that.

--a

On Tue, May 18, 2010 at 7:25 AM, Thomas Hofmann <[hidden email]> wrote:

> Hi,
>
>
>
> I have a map which I use as interface implementation. The code is formated
> in an unusual way:
>
>
>
>                   IPreferenceFilter filter = [
>
>                   getMapping: { return null
>
>                   },
>
>                   getScopes: {
>
>                         return [InstanceScope.SCOPE,
> ConfigurationScope.SCOPE]
>
>                   }
>
>                   ] as IPreferenceFilter
>
>
>
> Should such things be mentioned here or should I open a ticket somewhere?
>
>
>
> Thanks, Thomas

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

RE: Code formatting unusual

Thomas Hofmann
Turns out there was an import statement created at the top most line during saving and automatic organization of imports. The import statement was before the package statement which in turn messed up the overall structure of the file I believe which again had a negative impact on formatting.

After removal of the import it now looks much better.


-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On Behalf Of Andrew Eisenberg
Sent: Dienstag, 18. Mai 2010 17:47
To: [hidden email]
Subject: Re: [groovy-eclipse-plugin-user] Code formatting unusual

Hi Thomas,

I am not sure if this particular problem is included in the existing
jira issues, so could you please raise one for us and included the
code snippet?  The issue tracker is here:

http://jira.codehaus.org/browse/GRECLIPSE

Formatting and indentation are two areas that we will be focussing on
over the next little while and so your issue will be included in that.

--a

On Tue, May 18, 2010 at 7:25 AM, Thomas Hofmann <[hidden email]> wrote:

> Hi,
>
>
>
> I have a map which I use as interface implementation. The code is formated
> in an unusual way:
>
>
>
>                   IPreferenceFilter filter = [
>
>                   getMapping: { return null
>
>                   },
>
>                   getScopes: {
>
>                         return [InstanceScope.SCOPE,
> ConfigurationScope.SCOPE]
>
>                   }
>
>                   ] as IPreferenceFilter
>
>
>
> Should such things be mentioned here or should I open a ticket somewhere?
>
>
>
> Thanks, Thomas

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: Code formatting unusual

Andrew Eisenberg
Interesting.  Import statements are occasionally added above the
package declaration when the organize imports request comes at a time
when the file is unparseable.  Unfortunately, the groovy parser is not
as robust as we would like and does fail under some common syntax
errors.

We tend to fix these parser problems as they come up and then ensure
that the parser is recoverable under that particular syntax error.
So, if you find that you are creating syntax errors as you type that
cause unrecoverable parser problems, then please raise a jira for it
(we tend not to fix these things unless someone asks).

--a

On Tue, May 18, 2010 at 12:50 PM, Thomas Hofmann
<[hidden email]> wrote:

> Turns out there was an import statement created at the top most line during saving and automatic organization of imports. The import statement was before the package statement which in turn messed up the overall structure of the file I believe which again had a negative impact on formatting.
>
> After removal of the import it now looks much better.
>
>
> -----Original Message-----
> From: [hidden email] [mailto:[hidden email]] On Behalf Of Andrew Eisenberg
> Sent: Dienstag, 18. Mai 2010 17:47
> To: [hidden email]
> Subject: Re: [groovy-eclipse-plugin-user] Code formatting unusual
>
> Hi Thomas,
>
> I am not sure if this particular problem is included in the existing
> jira issues, so could you please raise one for us and included the
> code snippet?  The issue tracker is here:
>
> http://jira.codehaus.org/browse/GRECLIPSE
>
> Formatting and indentation are two areas that we will be focussing on
> over the next little while and so your issue will be included in that.
>
> --a
>
> On Tue, May 18, 2010 at 7:25 AM, Thomas Hofmann <[hidden email]> wrote:
>> Hi,
>>
>>
>>
>> I have a map which I use as interface implementation. The code is formated
>> in an unusual way:
>>
>>
>>
>>                   IPreferenceFilter filter = [
>>
>>                   getMapping: { return null
>>
>>                   },
>>
>>                   getScopes: {
>>
>>                         return [InstanceScope.SCOPE,
>> ConfigurationScope.SCOPE]
>>
>>                   }
>>
>>                   ] as IPreferenceFilter
>>
>>
>>
>> Should such things be mentioned here or should I open a ticket somewhere?
>>
>>
>>
>> Thanks, Thomas
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

RE: Code formatting unusual

Thomas Hofmann
Unfortunately, I cannot reproduce the situation as of now.

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On Behalf Of Andrew Eisenberg
Sent: Dienstag, 18. Mai 2010 21:56
To: [hidden email]
Subject: Re: [groovy-eclipse-plugin-user] Code formatting unusual

Interesting.  Import statements are occasionally added above the
package declaration when the organize imports request comes at a time
when the file is unparseable.  Unfortunately, the groovy parser is not
as robust as we would like and does fail under some common syntax
errors.

We tend to fix these parser problems as they come up and then ensure
that the parser is recoverable under that particular syntax error.
So, if you find that you are creating syntax errors as you type that
cause unrecoverable parser problems, then please raise a jira for it
(we tend not to fix these things unless someone asks).

--a

On Tue, May 18, 2010 at 12:50 PM, Thomas Hofmann
<[hidden email]> wrote:

> Turns out there was an import statement created at the top most line during saving and automatic organization of imports. The import statement was before the package statement which in turn messed up the overall structure of the file I believe which again had a negative impact on formatting.
>
> After removal of the import it now looks much better.
>
>
> -----Original Message-----
> From: [hidden email] [mailto:[hidden email]] On Behalf Of Andrew Eisenberg
> Sent: Dienstag, 18. Mai 2010 17:47
> To: [hidden email]
> Subject: Re: [groovy-eclipse-plugin-user] Code formatting unusual
>
> Hi Thomas,
>
> I am not sure if this particular problem is included in the existing
> jira issues, so could you please raise one for us and included the
> code snippet?  The issue tracker is here:
>
> http://jira.codehaus.org/browse/GRECLIPSE
>
> Formatting and indentation are two areas that we will be focussing on
> over the next little while and so your issue will be included in that.
>
> --a
>
> On Tue, May 18, 2010 at 7:25 AM, Thomas Hofmann <[hidden email]> wrote:
>> Hi,
>>
>>
>>
>> I have a map which I use as interface implementation. The code is formated
>> in an unusual way:
>>
>>
>>
>>                   IPreferenceFilter filter = [
>>
>>                   getMapping: { return null
>>
>>                   },
>>
>>                   getScopes: {
>>
>>                         return [InstanceScope.SCOPE,
>> ConfigurationScope.SCOPE]
>>
>>                   }
>>
>>                   ] as IPreferenceFilter
>>
>>
>>
>> Should such things be mentioned here or should I open a ticket somewhere?
>>
>>
>>
>> Thanks, Thomas
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email