#NEWLINE# @ lower_builtin ( 'list.remove' , types . List , types . Any ) #NEWLINE# def list_remove( context , builder , sig , args ) : #NEWLINE# #INDENT# def list_remove_impl( lst , value ) : #NEWLINE# #INDENT# for i in range ( len ( lst ) ) : #NEWLINE# #INDENT# if ( lst [ i ] == value ) : #NEWLINE# #INDENT# lst . pop ( i ) #NEWLINE# return #NEWLINE# #UNINDENT# #UNINDENT# raise ValueError ( 'list.remove(x): x not in list' ) #NEWLINE# #UNINDENT# return context . compile_internal ( builder , list_remove_impl , list_remove_impl , args )