开发者

Model sys's python implementation

开发者 https://www.devze.com 2022-12-16 10:29 出处:网络
pypy has many built-in functio开发者_StackOverflow中文版nuse python implementation.example:link but,i can\'t findmodel \'sys\' implementation.

pypy

has many built-in functio开发者_StackOverflow中文版n use python implementation.example:link

but,i can't find model 'sys' implementation.

how can i get it.

import sys
print help(sys)


The sys module is implemented in C: http://svn.python.org/view/python/trunk/Python/sysmodule.c?view=markup

There is no Python source for it, because it's entirely operating system interfaces that cannot be implemented in pure Python.


Abstraction can only be taken so far, Python strives to be a system/platform independent language and the sys module being what it is has to be platform specific and cannot be implemented in pure python.

0

精彩评论

暂无评论...
验证码 换一张
取 消