summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/cmTarget.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 602f826..badbd2b 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -243,8 +243,8 @@ bool cmTarget::HasCxx() const
for(std::vector<cmSourceFile*>::const_iterator i = m_SourceFiles.begin();
i != m_SourceFiles.end(); ++i)
{
- if((*i)->GetSourceExtension() != "c" &&
- (*i)->GetSourceExtension() != "h")
+ if(cmSystemTools::GetFileFormat((*i)->GetSourceExtension().c_str())
+ == cmSystemTools::CXX_FILE_FORMAT)
{
return true;
}