Commits

Amaury Forgeot d'Arc committed 140cb20

Use re.search() to find MSVC compiler version.
This will handle the Chinese translation of the compiler.

Comments (0)

Files changed (1)

rpython/translator/platform/windows.py

         # detect version of current compiler
         returncode, stdout, stderr = _run_subprocess(self.cc, '',
                                                      env=self.c_environ)
-        r = re.match(r'Microsoft.+C/C\+\+.+\s([0-9]+)\.([0-9]+).*', stderr)
+        r = re.search(r'Microsoft.+C/C\+\+.+\s([0-9]+)\.([0-9]+).*', stderr)
         if r is not None:
             self.version = int(''.join(r.groups())) / 10 - 60
         else: