]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
codegen: Skip visiting fast-vapis
authorRyan Lortie <desrt@desrt.ca>
Sat, 28 Aug 2010 17:39:26 +0000 (19:39 +0200)
committerJürg Billeter <j@bitron.ch>
Thu, 9 Sep 2010 13:54:18 +0000 (15:54 +0200)
Skip visiting fast-vapis in the code generator when not writing a header
file.  For builds with a very large number of fast-vapi files this can
reduce compile time by more than 50%.

codegen/valaccodebasemodule.vala

index 1fe41ffd1f50165424d43cc6974428c56085c4c5..6069360979b0991c1845d61a30439d35e326c237 100644 (file)
@@ -417,7 +417,8 @@ public class Vala.CCodeBaseModule : CodeGenerator {
                /* we're only interested in non-pkg source files */
                var source_files = context.get_source_files ();
                foreach (SourceFile file in source_files) {
-                       if (file.file_type != SourceFileType.PACKAGE) {
+                       if (file.file_type == SourceFileType.SOURCE ||
+                           (context.header_filename != null && file.file_type == SourceFileType.FAST)) {
                                file.accept (this);
                        }
                }