浏览代码

Fix the regular expression validator for target names.

Regression introduced by f1eacf0e07759b57d100dbf5d83c70e4028bcb54.
Target names have different valid contents to config names.
Stephen Kelly 13 年之前
父节点
当前提交
fb578c8635
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Source/cmGeneratorExpressionEvaluator.cxx

+ 1 - 1
Source/cmGeneratorExpressionEvaluator.cxx

@@ -299,7 +299,7 @@ struct TargetFilesystemArtifact : public cmGeneratorExpressionNode
     std::string name = *parameters.begin();
     std::string name = *parameters.begin();
 
 
     cmsys::RegularExpression targetValidator;
     cmsys::RegularExpression targetValidator;
-    targetValidator.compile("^[A-Za-z0-9_]+$");
+    targetValidator.compile("^[A-Za-z0-9_.-]+$");
     if (!targetValidator.find(name.c_str()))
     if (!targetValidator.find(name.c_str()))
       {
       {
       ::reportError(context, content->GetOriginalExpression(),
       ::reportError(context, content->GetOriginalExpression(),