#NEWLINE# def parse_immediate( string ) : #NEWLINE# #INDENT# if ( string . startswith ( '0x' ) or string . startswith ( '-0x' ) ) : #NEWLINE# #INDENT# immediate = int ( string , 16 ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# immediate = int ( string , 10 ) #NEWLINE# #UNINDENT# return immediate