[Gambas-user] Making code pretty
Kevin Fishburne
kevinfishburne at ...1887...
Thu Aug 4 21:38:47 CEST 2011
On 08/04/2011 03:07 PM, Ron wrote:
> Empty lines yes, keep them!
>
> But Kevin and I mean remove spaces on empty lines.
>
> Looks like this:
>
> Dim sTest as string
> ...<- remove these
> sTest = "this is a test"
>
> ' here above normal empty line, without spaces on it.
Agreed. I do use empty lines all the time, but death to unnecessary spaces.
It would also be nice if variable/procedure/etc. names were
autocorrected to use the case/capitalization of their declarative
statement. This is already done for things like Print, Public, Private,
Dim, Inc, Return, etc. For example:
Public SoEasyToRead As String
Print soeasytoread ' "soeasytoread" should be autocorrected, just like
"print" is, to match the case of the declaration "SoEasyToRead".
Public Function LovelyProcedureName(Input As String) As String
' Blah, blah.
End Sub
Print lovelyprocedurename("Please make me lovely") '
"lovelyprocedurename" should be autocorrected to match the function
declaration "LovelyProcedureName".
Also, changing the case of the declaration should automatically change
the case throughout the program. If that's too CPU intensive to do in
real-time, it could be done at compile or execution time.
--
Kevin Fishburne
Eight Virtues
www: http://sales.eightvirtues.com
e-mail: sales at ...1887...
phone: (770) 853-6271
More information about the User
mailing list