Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 09a1ce9

Browse files
committed
Add XXX: RUSTPYTHON
1 parent d9c808d commit 09a1ce9

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

Lib/site.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,7 @@ def joinuser(*args):
275275

276276
if os.name == "nt":
277277
base = os.environ.get("APPDATA") or "~"
278+
# XXX: RUSTPYTHON; please keep this change for site-packages
278279
return joinuser(base, "RustPython")
279280

280281
if sys.platform == "darwin" and sys._framework:
@@ -368,6 +369,7 @@ def getsitepackages(prefixes=None):
368369

369370
for libdir in libdirs:
370371
path = os.path.join(prefix, libdir,
372+
# XXX: RUSTPYTHON; please keep this change for site-packages
371373
"rustpython%d.%d" % sys.version_info[:2],
372374
"site-packages")
373375
sitepackages.append(path)

Lib/test/test_site.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,12 +288,14 @@ def test_getsitepackages(self):
288288
if sys.platlibdir != "lib":
289289
self.assertEqual(len(dirs), 2)
290290
wanted = os.path.join('xoxo', sys.platlibdir,
291+
# XXX: RUSTPYTHON
291292
'rustpython%d.%d' % sys.version_info[:2],
292293
'site-packages')
293294
self.assertEqual(dirs[0], wanted)
294295
else:
295296
self.assertEqual(len(dirs), 1)
296297
wanted = os.path.join('xoxo', 'lib',
298+
# XXX: RUSTPYTHON
297299
'rustpython%d.%d' % sys.version_info[:2],
298300
'site-packages')
299301
self.assertEqual(dirs[-1], wanted)

0 commit comments

Comments
 (0)