PHP 7.4.33
Preview: compat.py Size: 815 B
//lib/fm-agent/dependencies/simplejson/compat.py

"""Python 3 compatibility shims
"""
import sys
if sys.version_info[0] < 3:
    PY3 = False
    def b(s):
        return s
    try:
        from cStringIO import StringIO
    except ImportError:
        from StringIO import StringIO
    BytesIO = StringIO
    text_type = unicode
    binary_type = str
    string_types = (basestring,)
    integer_types = (int, long)
    unichr = unichr
    reload_module = reload
else:
    PY3 = True
    if sys.version_info[:2] >= (3, 4):
        from importlib import reload as reload_module
    else:
        from imp import reload as reload_module
    def b(s):
        return bytes(s, 'latin1')
    from io import StringIO, BytesIO
    text_type = str
    binary_type = bytes
    string_types = (str,)
    integer_types = (int,)
    unichr = chr

long_type = integer_types[-1]

Directory Contents

Dirs: 1 × Files: 10

Name Size Perms Modified Actions
tests DIR
- drwxr-xr-x 2025-06-19 05:07:59
Edit Download
815 B lrw-r--r-- 2025-06-18 20:44:50
Edit Download
14.18 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
28.44 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
1.74 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
2.88 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
217 B lrw-r--r-- 2025-06-18 20:44:50
Edit Download
2.90 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
1.11 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
55.34 KB lrwxr-xr-x 2025-06-18 20:44:50
Edit Download
23.19 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).