Cleanup: Depsgraph: Avoid transative includes and type aliases

Instead of the monolothic `depsgraph_type.hh` header that includes
most types used in the despgraph, just add includes where they are
actually necessary. Also remove the `using` keywords for `std` types.
The lack of specificity isn't considered good practice nowadays.

Removing unnecessary transitive includes can help improve compile
times because the time spent parsing headers decreases. Using the
"include what you use" pattern makes futher improvements much
easier too, since it the path to further reduce transitive includes
becomes much clearer.

Pull Request: https://projects.blender.org/blender/blender/pulls/133749
This commit is contained in:
Hans Goudey
2025-01-31 21:17:49 +01:00
committed by Hans Goudey
parent b53a372b6f
commit 3630fd78d5
47 changed files with 129 additions and 141 deletions

View File

@@ -60,14 +60,14 @@ bool stat_entry_comparator(const StatsEntry &a, const StatsEntry &b)
return a.time > b.time;
}
string gnuplotify_id_code(const string &name)
std::string gnuplotify_id_code(const std::string &name)
{
return string("") + name[0] + name[1];
return std::string("") + name[0] + name[1];
}
string gnuplotify_name(const string &name)
std::string gnuplotify_name(const std::string &name)
{
string result;
std::string result;
const int length = name.length();
for (int i = 0; i < length; i++) {
const char ch = name[i];