runtime/typemapping.py
branchpython3
changeset 3750 f62625418bff
parent 3395 93ad018fb602
child 3756 8db203310f68
equal deleted inserted replaced
3749:fda6c1a37662 3750:f62625418bff
     2 # -*- coding: utf-8 -*-
     2 # -*- coding: utf-8 -*-
     3 #
     3 #
     4 # See COPYING.Runtime file for copyrights details.
     4 # See COPYING.Runtime file for copyrights details.
     5 #
     5 #
     6 
     6 
     7 from __future__ import absolute_import
     7 
     8 import ctypes
     8 import ctypes
     9 from ctypes import *
     9 from ctypes import *
    10 from datetime import timedelta as td
    10 from datetime import timedelta as td
    11 
    11 
    12 ctypes.pythonapi.PyString_AsString.argtypes = (ctypes.c_void_p,)
    12 ctypes.pythonapi.PyString_AsString.argtypes = (ctypes.c_void_p,)
    72     }
    72     }
    73 
    73 
    74 TypeTranslator = SameEndianessTypeTranslator
    74 TypeTranslator = SameEndianessTypeTranslator
    75 
    75 
    76 # Construct debugger natively supported types
    76 # Construct debugger natively supported types
    77 DebugTypesSize = dict([(key, sizeof(t)) for key, (t, p, u) in SameEndianessTypeTranslator.iteritems() if t is not None])
    77 DebugTypesSize = dict([(key, sizeof(t)) for key, (t, p, u) in SameEndianessTypeTranslator.items() if t is not None])
    78 
    78 
    79 
    79 
    80 def UnpackDebugBuffer(buff, indexes):
    80 def UnpackDebugBuffer(buff, indexes):
    81     res = []
    81     res = []
    82     buffoffset = 0
    82     buffoffset = 0