r5672: Use switch_type() and the token storage mechanism for unions:
[samba.git] / source4 / build / pidl / pidl.pl
index 6bbb2ec78c946df75f135a30a5df00071db8f616..9e1ce48467e1bc2b0e73b3804ce7713ae60ab874 100755 (executable)
@@ -137,6 +137,7 @@ sub process_file($)
        if ($opt_parse) {
                $pidl = IdlParse($idl_file);
                defined @$pidl || die "Failed to parse $idl_file";
+               typelist::LoadIdl($pidl);
                IdlValidator::Validate($pidl);
                if ($opt_keep && !util::SaveStructure($pidl_file, $pidl)) {
                            die "Failed to save $pidl_file\n";
@@ -157,10 +158,6 @@ sub process_file($)
                unlink($tempfile);
        }
 
-       if ($opt_header || $opt_parser || $opt_com_header || $opt_dcom_proxy) {
-               typelist::LoadIdl($pidl);
-       }
-
        if ($opt_com_header) {
                my $res = COMHeader::Parse($pidl);
                if ($res) {