📄 __init__.py.svn-base
字号:
############################################################################ # Psyco top-level file of the Psyco package.# Copyright (C) 2001-2002 Armin Rigo et.al."""Psyco -- the Python Specializing Compiler.Typical usage: add the following lines to your application's main module:try: import psyco psyco.profile()except: print 'Psyco not found, ignoring it'"""############################################################################# This module is present to make 'psyco' a package and to# publish the main functions and variables.## More documentation can be found in core.py.## Try to import the dynamic-loading _psyco and report errorstry: import _psycoexcept ImportError, e: extramsg = '' import sys, imp try: file, filename, (suffix, mode, type) = imp.find_module('_psyco', __path__) except ImportError: ext = [suffix for suffix, mode, type in imp.get_suffixes() if type == imp.C_EXTENSION] if ext: extramsg = (" (cannot locate the compiled extension '_psyco%s' " "in the package path '%s')" % (ext[0], '; '.join(__path__))) else: extramsg = (" (check that the compiled extension '%s' is for " "the correct Python version; this is Python %s)" % (filename, sys.version.split()[0])) raise ImportError, str(e) + extramsg# Publish important data by importing them in the packagefrom support import __version__, error, warning, _getrealframe, _getemulframefrom support import version_info, __version__ as hexversionfrom core import full, profile, background, runonly, stop, cannotcompilefrom core import log, bind, unbind, proxy, unproxy, dumpcodebuffrom _psyco import setfiltertry: from _psyco import compact, compacttype # Python 2.2 and above onlyexcept ImportError: pass
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -