     
     /// `true` if the rule creates ndoes, false otherwise
     public var scanning : Bool {
-        return behaviour.token != nil
+        if case .scanning = behaviour.kind {
+            return true
+        }
+        return false
     }
 
     /**

    
    /// `true` if the rule creates ndoes, false otherwise
    public var structural : Bool {
        if case .structural(_) = behaviour.kind {
            return true
        }
        return false
    }
    
    /// `true` if the rule creates ndoes, false otherwise

        //Prepare for any lookahead by putting a fake IR in place if is lookahead
        //as well as taking an additional mark to ensure position will always be
        //where it was
        let printDebugMessages = false
        let ir = behaviour.lookahead ? LookAheadIR() : ir
        if behaviour.lookahead {
            lexer.mark(skipping:true)
