fn process_normal(&mut self, ch: char) {
        match ch {
            // push digits to the stack
            '0'...'9' | 'a'...'f' => push_digit(self, ch),

            // modal operators
            '"' => self.execution_mode = Mode::Quoted,
            '#' => {self.increment_cursor();},

            // arithmetic operators
            '+' => addition(self),
            '-' => subtraction(self),
            '*' => multiply(self),
            '/' => divide(self),
            '%' => modulo(self),

            // logical operators
            '!' => logical_negation(self),
            '`' => greater_than(self),

            // directional operations
            '>' => self.direction = Right,
            '<' => self.direction = Left,
            '^' => self.direction = Up,
            'v' => self.direction = Down,
            '?' => self.direction = rand::random::<Direction>(),

            // branching operators
            '|' => veritical_if(self),
            '_' => horizontal_if(self),

            // stack manipulation operators
            '$' => {self.stack.pop();},
            ':' => self.stack.duplicate_top(),
            '\\' => self.stack.swap_top(),

            // input operators
            '&' => read_integer(self),
            '~' => read_char(self),

            // output operators
            '.' => print_digit(self),
            ',' => print_char(self),

            // load/store operations
            'p' => put(self),
            'g' => get(self),


            // end the program
            '@' => end_program(self),
            _ => (),
        };

    }
// process_normal reads the current character and process it according to normal rules
process_normal reads the current character and process it according to normal rules
process_normal reads the current character and process it according to normal rules
fn process_normal(&mut self, ch: char) {
        match ch {
            // push digits to the stack
            '0'...'9' | 'a'...'f' => push_digit(self, ch),
            // modal operators
            '"' => self.execution_mode = Mode::Quoted,
            '#' => {self.increment_cursor();},
            // arithmetic operators
            '+' => addition(self),
            '-' => subtraction(self),
            '*' => multiply(self),
            '/' => divide(self),
            '%' => modulo(self),
            // logical operators
            '!' => logical_negation(self),
            '`' => greater_than(self),
            // directional operations
            '>' => self.direction = Right,
            '<' => self.direction = Left,
            '^' => self.direction = Up,
            'v' => self.direction = Down,
            '?' => self.direction = rand::random::<Direction>(),
            // branching operators
            '|' => veritical_if(self),
            '_' => horizontal_if(self),
            // stack manipulation operators
            '$' => {self.stack.pop();},
            ':' => self.stack.duplicate_top(),
            '\\' => self.stack.swap_top(),
            // input operators
            '&' => read_integer(self),
            '~' => read_char(self),
            // output operators
            '.' => print_digit(self),
            ',' => print_char(self),
            // load/store operations
            'p' => put(self),
            'g' => get(self),
            // end the program
            '@' => end_program(self),
            _ => (),
        };
    }
fn process_normal ( & mut self , ch : char ) { match ch { // push digits to the stack '0' ... '9' | 'a' ... 'f' => push_digit ( self , ch ) , // modal operators '"' => self . execution_mode = Mode :: Quoted , '#' => { self . increment_cursor ( ) ; } , // arithmetic operators '+' => addition ( self ) , '-' => subtraction ( self ) , '*' => multiply ( self ) , '/' => divide ( self ) , '%' => modulo ( self ) , // logical operators '!' => logical_negation ( self ) , '`' => greater_than ( self ) , // directional operations '>' => self . direction = Right , '<' => self . direction = Left , '^' => self . direction = Up , 'v' => self . direction = Down , '?' => self . direction = rand :: random :: < Direction > ( ) , // branching operators '|' => veritical_if ( self ) , '_' => horizontal_if ( self ) , // stack manipulation operators '$' => { self . stack . pop ( ) ; } , ':' => self . stack . duplicate_top ( ) , '\\' => self . stack . swap_top ( ) , // input operators '&' => read_integer ( self ) , '~' => read_char ( self ) , // output operators '.' => print_digit ( self ) , ',' => print_char ( self ) , // load/store operations 'p' => put ( self ) , 'g' => get ( self ) , // end the program '@' => end_program ( self ) , _ => ( ) , } ; }
process_normal reads the current character and process it according to normal rules
process_normal reads the current character and process it according to normal rules
&mut self
ch
char
&mut self
ch
char