<s> import idaapi <EOL> def cb ( * args ) : <EOL> print ( "<STR_LIT>" ) <EOL> return <NUM_LIT:1> <EOL> try : <EOL> ex_addmenu_item_ctx <EOL> idaapi . del_menu_item ( ex_addmenu_item_ctx ) <EOL> print ( "<STR_LIT>" ) <EOL> del ex_addmenu_item_ctx <EOL> except : <EOL> ex_addmenu_item_ctx = idaapi . add_menu_item ( "<STR_LIT>" , "<STR_LIT:X>" , "<STR_LIT>" , <NUM_LIT:0> , cb , tuple ( "<STR_LIT>" ) ) <EOL> if ex_addmenu_item_ctx is None : <EOL> print ( "<STR_LIT>" ) <EOL> del ex_addmenu_item_ctx <EOL> else : <EOL> print ( "<STR_LIT>" ) </s>
