summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-12-07 20:23:53 (GMT)
committerBrad King <brad.king@kitware.com>2021-12-08 15:03:48 (GMT)
commitc749982c13fa00a968fe0b171946b96d0884ea54 (patch)
tree131974537adb1ee54467d2601699a723ff30d710 /Source/cmTarget.h
parent3d378541bb22f00e3a22bf5f12e97b7943a81294 (diff)
downloadCMake-c749982c13fa00a968fe0b171946b96d0884ea54.zip
CMake-c749982c13fa00a968fe0b171946b96d0884ea54.tar.gz
CMake-c749982c13fa00a968fe0b171946b96d0884ea54.tar.bz2
cmTargetPropertyComputer: Simplify by restoring use of cmMakefile
Logically revert commit 390a7d8647 (cmTargetPropertyComputer: Implement GetProperty without cmMakefile, 2016-10-13, v3.8.0-rc1~445^2~9). It relied on using `cmListFileBacktrace` to get a scope in which to look up policies. This does remove a backtrace from `LOCATION` property errors at generate time, but the backtrace we reported before was incorrect. It pointed at the addition of a target, not to the reference to the property.
Diffstat (limited to 'Source/cmTarget.h')
-rw-r--r--Source/cmTarget.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index 27b325a..c4314a4 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -12,7 +12,6 @@
#include <vector>
#include "cmAlgorithms.h"
-#include "cmListFileCache.h"
#include "cmPolicies.h"
#include "cmStateTypes.h"
#include "cmStringAlgorithms.h"
@@ -23,12 +22,18 @@ class cmCustomCommand;
class cmFileSet;
class cmGlobalGenerator;
class cmInstallTargetGenerator;
+class cmListFileBacktrace;
+class cmListFileContext;
class cmMakefile;
-class cmMessenger;
class cmPropertyMap;
class cmSourceFile;
class cmTargetInternals;
+template <typename T>
+class BT;
+template <typename T>
+class BTs;
+
/** \class cmTarget
* \brief Represent a library or executable target loaded from a makefile.
*
@@ -184,8 +189,7 @@ public:
std::string const& GetSafeProperty(std::string const& prop) const;
bool GetPropertyAsBool(const std::string& prop) const;
void CheckProperty(const std::string& prop, cmMakefile* context) const;
- cmValue GetComputedProperty(const std::string& prop, cmMessenger* messenger,
- cmListFileBacktrace const& context) const;
+ cmValue GetComputedProperty(const std::string& prop, cmMakefile& mf) const;
//! Get all properties
cmPropertyMap const& GetProperties() const;