Package vstruct :: Package defs :: Package macho :: Module stabs
[hide private]
[frames] | no frames]

Source Code for Module vstruct.defs.macho.stabs

 1  import vstruct 
 2   
 3  from vstruct.primitives import * 
 4  from vstruct.defs.macho.const import * 
 5   
6 -class nlist(vstruct.VStruct):
7 ''' 8 A symbol table entry in a Mach-O binary is called an nlist. 9 '''
10 - def __init__(self):
11 vstruct.VStruct.__init__(self) 12 self.n_strx = v_uint32() # index into the string table 13 self.n_type = v_uint8() # type flag (see const...) 14 self.n_sect = v_uint8() # section number or NO_SECT (index from 1...) 15 self.n_desc = v_uint16() # desription (see const...) 16 self.n_value = v_uint32() # value of this symbol (or stab offset)
17
18 -class nlist64(vstruct.VStruct):
19
20 - def __init__(self):
21 vstruct.VStruct.__init__(self) 22 self.n_strx = v_uint32() 23 self.n_type = v_uint8() 24 self.n_sect = v_uint8() 25 self.n_desc = v_uint16() 26 self.n_value = v_uint64()
27