[fpc-pascal] FreePascal Coding style

Vinzent Hoefler JeLlyFish.software at gmx.net
Tue Jan 22 15:27:21 CET 2008


On Tuesday 22 January 2008 15:18, mm wrote:
> Vinzent Hoefler a écrit :
> > 2) If I put the tabstop "typographically correct" as it should be
> > (that means: right before the parentheses)[1],
> > [...]
> >
> > [1] In normal text( you don't write parentheses like that ), do
> > you?
>
> And what about math functions? Is "f (x)" more typographically
> correct than "f(x)"? ;-)

Due to the lack of differently spaced spaces, yes. ;)

However, the function name and the parameters should also be visually 
distinct, so the former variant is to be preferred.

Especially if we start the tabular layout again, then

|function Random (l : LongInt) : LongInt;
|function Random (l : Int64)   : Int64;
|function Random               : Extended;

looks better than

|function Random(l : LongInt) : LongInt;
|function Random(l : Int64)   : Int64;
|function Random              : Extended;

because in the first variant there's a clear visual distinction between 
the function name and the parameter name.

But, either variant is still superior to "f( x )".


Vinzent.



More information about the fpc-pascal mailing list