SF.net SVN: geany:[4168] trunk/scripts/fix-alignment.pl

ntrel at users.sourceforge.net ntrel at xxxxx
Mon Sep 7 15:31:46 UTC 2009


Revision: 4168
          http://geany.svn.sourceforge.net/geany/?rev=4168&view=rev
Author:   ntrel
Date:     2009-09-07 15:31:46 +0000 (Mon, 07 Sep 2009)

Log Message:
-----------
Space commas.

Modified Paths:
--------------
    trunk/scripts/fix-alignment.pl

Modified: trunk/scripts/fix-alignment.pl
===================================================================
--- trunk/scripts/fix-alignment.pl	2009-09-07 15:13:50 UTC (rev 4167)
+++ trunk/scripts/fix-alignment.pl	2009-09-07 15:31:46 UTC (rev 4168)
@@ -57,6 +57,9 @@
 		# space ternary conditional operator
 		$line =~ s/\s*\?\s*(.+?)\s*:\s*/ ? $1 : /g;
 
+		# space comma operator (allowing for possible alignment space afterwards)
+		$line =~ s/\s*,(\S)/, $1/g;
+
 		# space after statements
 		my $statements = 'for|if|while|switch';
 		$line =~ s/\b($statements)\b\s*/$1 /g;


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the Commits mailing list