trepan/processor/command/frame.py
def one_arg_run(self, position_str):
        '''The simple case: thread frame switching has been done or is
        not needed and we have an explicit position number as a string'''
        frame_num = self.proc.get_an_int(position_str,
                                         ("The 'frame' command requires a" +
                                          " frame number. Got: %s") %
                                         position_str)
        if frame_num is None: return False

        i_stack = len(self.proc.stack)
        if i_stack == 0:
            self.errmsg('No frames recorded')
            return False

        if frame_num < -i_stack or frame_num > i_stack-1:
            self.errmsg(('Frame number has to be in the range %d to %d.' +
                         ' Got: %d (%s).') % (-i_stack, i_stack-1,
                                               frame_num, position_str))
            return False
        else:
            Mframe.adjust_frame(self.proc, 'frame', pos=frame_num,
                                absolute_pos=True)
            return True
        return
def one_arg_run(self, position_str):
        '''The simple case: thread frame switching has been done or is
        not needed and we have an explicit position number as a string'''
        frame_num = self.proc.get_an_int(position_str,
                                         ("The 'frame' command requires a" +
                                          " frame number. Got: %s") %
                                         position_str)
        if frame_num is None: return False

        i_stack = len(self.proc.stack)
        if i_stack == 0:
            self.errmsg('No frames recorded')
            return False

        if frame_num < -i_stack or frame_num > i_stack-1:
            self.errmsg(('Frame number has to be in the range %d to %d.' +
                         ' Got: %d (%s).') % (-i_stack, i_stack-1,
                                               frame_num, position_str))
            return False
        else:
            Mframe.adjust_frame(self.proc, 'frame', pos=frame_num,
                                absolute_pos=True)
            return True
        return
def one_arg_run ( self , position_str ) : frame_num = self . proc . get_an_int ( position_str , ( "The 'frame' command requires a" + " frame number. Got: %s" ) % position_str ) if frame_num is None : return False i_stack = len ( self . proc . stack ) if i_stack == 0 : self . errmsg ( 'No frames recorded' ) return False if frame_num < - i_stack or frame_num > i_stack - 1 : self . errmsg ( ( 'Frame number has to be in the range %d to %d.' + ' Got: %d (%s).' ) % ( - i_stack , i_stack - 1 , frame_num , position_str ) ) return False else : Mframe . adjust_frame ( self . proc , 'frame' , pos = frame_num , absolute_pos = True ) return True return
The simple case: thread frame switching has been done or is
        not needed and we have an explicit position number as a string
The simple case : thread frame switching has been done or is not needed and we have an explicit position number as a string