genwincodec.py 文件源码

python
阅读 24 收藏 0 点赞 0 评论 0

项目:oil 作者: oilshell 项目源码 文件源码
def genwincodec(codepage):
    import platform
    map = genwinmap(codepage)
    encodingname = 'cp%d' % codepage
    code = codegen("", map, encodingname)
    # Replace first lines with our own docstring
    code = '''\
"""Python Character Mapping Codec %s generated on Windows:
%s with the command:
  python Tools/unicode/genwincodec.py %s
"""#"
''' % (encodingname, ' '.join(platform.win32_ver()), codepage
      ) + code.split('"""#"', 1)[1]

    print code
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号