Better document how Position c'tor works

Renamed a bit the functions to be more clear what
we actually are doing when we craete a Position object
and explained how StateInfo works.

No functional change.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
Marco Costalba
2010-01-25 12:04:00 +01:00
parent b1ac6c69a0
commit 84ec1f7331
4 changed files with 44 additions and 29 deletions

View File

@@ -54,7 +54,7 @@ namespace {
// The root position. This is set up when the user (or in practice, the GUI)
// sends the "position" UCI command. The root position is sent to the think()
// function when the program receives the "go" command.
Position RootPosition;
Position RootPosition(StartPosition);
// Local functions
bool handle_command(const string& command);
@@ -210,7 +210,7 @@ namespace {
}
// Our StateInfo st is about going out of scope so copy
// its content inside RootPosition before they disappear.
RootPosition.saveState();
RootPosition.detach();
}
}
}