javaweb-people
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javaweb-people] Re: gcj vs classpath merge status


From: Nic Ferrier
Subject: [Javaweb-people] Re: gcj vs classpath merge status
Date: 29 Jan 2002 21:05:32 +0000

"Etienne M. Gagnon" <address@hidden> writes:

> Nic Ferrier wrote: 
>  
> >  
> > In other words all brackets have a space in front of them except 
> > method invocations. 
> >  
> > This is very useful coz it means you can search for method 
> > declerations by name quite easily. 
>  
>  
> Isn't etags meant for this? 

Yes but I don't use it. You have to constantly re-generate the tag
files.


>I dislike somewhat the assymmetry of your proposal. 

It may be assymetrical but it is still nice. It's also pretty natural,
I find using a space in front of *every* brace to be a bit of
overkill, though it's useful in dense C code Java very rarely gets
that dense.

The utility of a coding style is not just defined by it's symmetry.


> > However, since we are supposed to all code to a style it would be 
> > useful if we all agreed on something. 
>  
> It is simpler to have an automated tool; then you can (a) change
> idea, and (b) reindent all the code according to the new idea by
> simply changing a switch on the command line...

I agree, I think a command line tool is best. However, it's still best
to have the *right* indentation in CVS. That encourages people to use
the right style.


> I think that indent is not the right approach, here.  Java, unlike
> C/C++, has a clean syntax.  So you can build a "real parser" for it,
> and thus have a **robust** indenter that handles **all** cases
> precisely.  If I had time, I would write a robust indenter in Java
> using SableCC, but I do not have the time...

I suggested indent because that's what GNU programmers naturally
expect to use. There's great value in that, we have a more consitent
development environment than any other place I know.

Besides, I think indent will do the job "well enough" and I'm not
offering to write a parser based solution  /8-)


Nic



reply via email to

[Prev in Thread] Current Thread [Next in Thread]