Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slow compiling because of wrong interface header file design #7

Open
mlathan opened this issue Jul 19, 2013 · 1 comment
Open

Slow compiling because of wrong interface header file design #7

mlathan opened this issue Jul 19, 2013 · 1 comment

Comments

@mlathan
Copy link
Member

mlathan commented Jul 19, 2013

Migrations have to include api.h to be implemented at the moment. api.h is a rather complex header file which polutes every migration header file with unnecessery command and structure classes at the moment.

Specify a tightly defined header file to define a new migration (HPP). Specify a header file for new migration implemantions (CPP).

@arBmind
Copy link
Member

arBmind commented Jun 9, 2014

The compile time impact of the current structure should be quite low. Migration Headers are included at most twice.

  1. The migration implementation, which require api.h definitions.
  2. The migration registration (as long as auto-registration does not work) includes all the migrations. The api.h is only included from the first, so impact should be low.

Additionally the QSqlMigrator is an external dependency for projects that use it. Therefore it's a good idea to include the api.h in the precompiled header. Which should eliminate almost all of it's compile time costs.

On the other hand is the ease of us. Using the "api.h" makes the migrations really easy to write or generate with a macro.

In the end it's always a trade off.

arBmind added a commit that referenced this issue Sep 20, 2021
* modernize Appveyor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants