Skip to content

Commit

Permalink
distutils: fix msvc9 import
Browse files Browse the repository at this point in the history
Co-authored-by: Алексей <[email protected]>
  • Loading branch information
lazka and Alexpux committed Jul 19, 2023
1 parent 6cd9dca commit 812e7ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Lib/distutils/msvc9compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -291,8 +291,6 @@ def query_vcvarsall(version, arch="x86"):

# More globals
VERSION = get_build_version()
if VERSION < 8.0:
raise DistutilsPlatformError("VC %0.1f is not supported by this module" % VERSION)
# MACROS = MacroExpander(VERSION)

class MSVCCompiler(CCompiler) :
Expand Down Expand Up @@ -327,6 +325,8 @@ class MSVCCompiler(CCompiler) :

def __init__(self, verbose=0, dry_run=0, force=0):
CCompiler.__init__ (self, verbose, dry_run, force)
if VERSION < 8.0:
raise DistutilsPlatformError("VC %0.1f is not supported by this module" % VERSION)
self.__version = VERSION
self.__root = r"Software\Microsoft\VisualStudio"
# self.__macros = MACROS
Expand Down

0 comments on commit 812e7ee

Please sign in to comment.