svn commit: samba r22640 - in branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4: .

metze at samba.org metze at samba.org
Wed May 2 18:00:03 GMT 2007


Author: metze
Date: 2007-05-02 18:00:02 +0000 (Wed, 02 May 2007)
New Revision: 22640

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=22640

Log:
- generate nicer output
- fix compiler warning about unused ';'

metze
Modified:
   branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm


Changeset:
Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm
===================================================================
--- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm	2007-05-02 16:10:23 UTC (rev 22639)
+++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm	2007-05-02 18:00:02 UTC (rev 22640)
@@ -43,7 +43,7 @@
 	}
 
 	if ($ret) {
-		pidl "/* [" . substr($ret, 0, -1) . "] */";
+		pidl " /* [" . substr($ret, 0, -1) . "] */";
 	}
 }
 
@@ -108,10 +108,12 @@
 	    pidl tabs()."char _empty_;\n";
     }
     $tab_depth--;
-    pidl tabs()."}";
+
+    pidl "};";
 	if (defined $struct->{PROPERTIES}) {
 		HeaderProperties($struct->{PROPERTIES}, []);
 	}
+    pidl "\n\n";
 }
 
 #####################################################################
@@ -132,10 +134,10 @@
 	}
 	pidl "\n";
 	$tab_depth--;
-	pidl "}\n";
+	pidl "};\n";
 	pidl "#else\n";
 	my $count = 0;
-	pidl "enum $name { __donnot_use_enum_$name=0x7FFFFFFF}\n";
+	pidl "enum $name { __donnot_use_enum_$name=0x7FFFFFFF};\n";
 	my $with_val = 0;
 	my $without_val = 0;
 	foreach my $e (@{$enum->{ELEMENTS}}) {
@@ -191,11 +193,12 @@
 		}
 	}
 	$tab_depth--;
-	pidl "}";
 
+	pidl "};";
 	if (defined $union->{PROPERTIES}) {
 		HeaderProperties($union->{PROPERTIES}, []);
 	}
+	pidl "\n\n";
 }
 
 #####################################################################
@@ -297,7 +300,7 @@
 	    HeaderFunctionInOut($fn, "in");
 	    HeaderFunctionInOut($fn, "inout");
 	    $tab_depth--;
-	    pidl tabs()."} in;\n\n";
+	    pidl tabs()."} in;\n";
 	    $needed++;
     }
 
@@ -311,7 +314,7 @@
 		    pidl tabs().mapTypeName($fn->{RETURN_TYPE}) . " result;\n";
 	    }
 	    $tab_depth--;
-	    pidl tabs()."} out;\n\n";
+	    pidl tabs()."} out;\n";
 	    $needed++;
     }
 
@@ -362,11 +365,6 @@
 		HeaderUnion($d, $d->{NAME}) if ($d->{TYPE} eq "UNION");
 		HeaderEnum($d, $d->{NAME}) if ($d->{TYPE} eq "ENUM");
 		HeaderBitmap($d, $d->{NAME}) if ($d->{TYPE} eq "BITMAP");
-		pidl ";\n\n" if ($d->{TYPE} eq "BITMAP" or 
-			             $d->{TYPE} eq "STRUCT" or 
-						 $d->{TYPE} eq "TYPEDEF" or 
-						 $d->{TYPE} eq "UNION" or 
-						 $d->{TYPE} eq "ENUM");
 	}
 
 	foreach my $d (@{$interface->{DATA}}) {



More information about the samba-cvs mailing list