|
@@ -438,6 +438,19 @@ void cmListFileBacktrace::PrintCallStack(std::ostream& out) const
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+size_t cmListFileBacktrace::Depth() const
|
|
|
+{
|
|
|
+ size_t depth = 0;
|
|
|
+ if (this->Cur == nullptr) {
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+
|
|
|
+ for (Entry* i = this->Cur->Up; i; i = i->Up) {
|
|
|
+ depth++;
|
|
|
+ }
|
|
|
+ return depth;
|
|
|
+}
|
|
|
+
|
|
|
std::ostream& operator<<(std::ostream& os, cmListFileContext const& lfc)
|
|
|
{
|
|
|
os << lfc.FilePath;
|