Fix handling of format strings to work with python 2.6
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@216314 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2c26213103
commit
ae6e58c561
@ -307,9 +307,9 @@ class Configuration(object):
|
|||||||
for feature, loc in locales[platform.system()].items():
|
for feature, loc in locales[platform.system()].items():
|
||||||
try:
|
try:
|
||||||
locale.setlocale(locale.LC_ALL, loc)
|
locale.setlocale(locale.LC_ALL, loc)
|
||||||
self.config.available_features.add('locale.{}'.format(feature))
|
self.config.available_features.add('locale.{0}'.format(feature))
|
||||||
except:
|
except:
|
||||||
self.lit_config.warning('The locale {} is not supported by '
|
self.lit_config.warning('The locale {0} is not supported by '
|
||||||
'your platform. Some tests will be '
|
'your platform. Some tests will be '
|
||||||
'unsupported.'.format(loc))
|
'unsupported.'.format(loc))
|
||||||
locale.setlocale(locale.LC_ALL, default_locale)
|
locale.setlocale(locale.LC_ALL, default_locale)
|
||||||
@ -384,7 +384,7 @@ class Configuration(object):
|
|||||||
if std is None:
|
if std is None:
|
||||||
std = 'c++11'
|
std = 'c++11'
|
||||||
self.lit_config.note('using default std: \'-std=c++11\'')
|
self.lit_config.note('using default std: \'-std=c++11\'')
|
||||||
self.compile_flags += ['-std={}'.format(std)]
|
self.compile_flags += ['-std={0}'.format(std)]
|
||||||
self.config.available_features.add(std)
|
self.config.available_features.add(std)
|
||||||
|
|
||||||
def configure_sanitizer(self):
|
def configure_sanitizer(self):
|
||||||
@ -401,7 +401,7 @@ class Configuration(object):
|
|||||||
self.config.available_features.add('msan')
|
self.config.available_features.add('msan')
|
||||||
else:
|
else:
|
||||||
self.lit_config.fatal('unsupported value for '
|
self.lit_config.fatal('unsupported value for '
|
||||||
'libcxx_use_san: {}'.format(san))
|
'libcxx_use_san: {0}'.format(san))
|
||||||
|
|
||||||
def configure_triple(self):
|
def configure_triple(self):
|
||||||
# Get or infer the target triple.
|
# Get or infer the target triple.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user