- const string StartPositionFEN = "rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1";
-
- // UCIParser is a class for parsing UCI input. The class
- // is actually a string stream built on a given input string.
- typedef istringstream UCIParser;
-
- // Local functions
- bool handle_command(Position& pos, const string& command);
- void set_option(UCIParser& uip);
- void set_position(Position& pos, UCIParser& uip);
- bool go(Position& pos, UCIParser& uip);
- void perft(Position& pos, UCIParser& uip);
-}
-
-
-////
-//// Functions
-////
-
-/// uci_main_loop() is the only global function in this file. It is
-/// called immediately after the program has finished initializing.
-/// The program remains in this loop until it receives the "quit" UCI
-/// command. It waits for a command from the user, and passes this
-/// command to handle_command() and also intercepts EOF from stdin,
-/// by translating EOF to the "quit" command. This ensures that Stockfish
-/// exits gracefully if the GUI dies unexpectedly.