[cfe-commits] r116269 - /cfe/trunk/lib/Basic/Version.cpp

Daniel Dunbar daniel at zuster.org
Mon Oct 11 16:50:34 PDT 2010


Author: ddunbar
Date: Mon Oct 11 18:50:34 2010
New Revision: 116269

URL: http://llvm.org/viewvc/llvm-project?rev=116269&view=rev
Log:
Basic: Tweak attempt to make version tags work from 'svn export's again, clip
off the extra parts of the $URL$ SVN keyword.

Modified:
    cfe/trunk/lib/Basic/Version.cpp

Modified: cfe/trunk/lib/Basic/Version.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/Version.cpp?rev=116269&r1=116268&r2=116269&view=diff
==============================================================================
--- cfe/trunk/lib/Basic/Version.cpp (original)
+++ cfe/trunk/lib/Basic/Version.cpp Mon Oct 11 18:50:34 2010
@@ -31,8 +31,10 @@
   // If the SVN_REPOSITORY is empty, try to use the SVN keyword. This helps us
   // pick up a tag in an SVN export, for example.
   static llvm::StringRef SVNRepository("$URL$");
-  if (URL.empty())
-    URL = SVNRepository.split(':').second;
+  if (URL.empty()) {
+    URL = SVNRepository.slice(SVNRepository.find(':'),
+                              SVNRepository.find("/lib/Basic"));
+  }
 
   // Strip off version from a build from an integration branch.
   URL = URL.slice(0, URL.find("/src/tools/clang"));





More information about the cfe-commits mailing list