浏览代码

cmState::Snapshot: Provide accessor for the cmState.

Stephen Kelly 10 年之前
父节点
当前提交
a824415724
共有 2 个文件被更改,包括 7 次插入0 次删除
  1. 5 0
      Source/cmState.cxx
  2. 2 0
      Source/cmState.h

+ 5 - 0
Source/cmState.cxx

@@ -787,3 +787,8 @@ cmState::Snapshot cmState::Snapshot::GetBuildsystemDirectoryParent() const
 
   return snapshot;
 }
+
+cmState* cmState::Snapshot::GetState() const
+{
+  return this->State;
+}

+ 2 - 0
Source/cmState.h

@@ -47,6 +47,8 @@ public:
     bool IsValid() const;
     Snapshot GetBuildsystemDirectoryParent() const;
 
+    cmState* GetState() const;
+
   private:
     void ComputeRelativePathTopSource();
     void ComputeRelativePathTopBinary();