Position: fix a couple of Intel compiler warnings

Plus usual trailing whitespace.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
Marco Costalba
2008-10-26 13:23:27 +01:00
parent 8a85007023
commit a5c1b3e8f6
2 changed files with 31 additions and 35 deletions

View File

@@ -39,7 +39,7 @@ namespace {
/// Variables
MovePicker::MovegenPhase PhaseTable[32];
MovePicker::MovegenPhase PhaseTable[32];
int MainSearchPhaseIndex;
int EvasionsPhaseIndex;
int QsearchWithChecksPhaseIndex;
@@ -62,7 +62,7 @@ namespace {
/// move ordering is at the current node.
MovePicker::MovePicker(const Position& p, bool pvnode, Move ttm, Move mk,
Move k1, Move k2, Depth d) : pos(p) {
Move k1, Move k2, Depth d) : pos(p) {
pvNode = pvnode;
ttMove = ttm;
mateKiller = (mk == ttm)? MOVE_NONE : mk;
@@ -147,13 +147,13 @@ Move MovePicker::get_next_move() {
break;
case PH_EVASIONS:
assert(pos.is_check());
assert(pos.is_check());
numOfMoves = generate_evasions(pos, moves);
score_evasions();
movesPicked = 0;
break;
case PH_QCAPTURES:
case PH_QCAPTURES:
numOfMoves = generate_captures(pos, moves);
score_qcaptures();
movesPicked = 0;
@@ -172,8 +172,6 @@ Move MovePicker::get_next_move() {
return MOVE_NONE;
}
}
assert(false);
return MOVE_NONE;
}
@@ -192,7 +190,7 @@ Move MovePicker::get_next_move(Lock &lock) {
if (m == MOVE_NONE)
finished = true;
lock_release(&lock);
lock_release(&lock);
return m;
}
@@ -273,20 +271,20 @@ void MovePicker::score_qcaptures() {
}
/// find_best_index() loops across the moves and returns index of
/// the highest scored one.
int MovePicker::find_best_index() {
int bestScore = -10000000, bestIndex = -1;
for (int i = movesPicked; i < numOfMoves; i++)
if (moves[i].score > bestScore)
{
bestIndex = i;
bestScore = moves[i].score;
}
return bestIndex;
/// find_best_index() loops across the moves and returns index of
/// the highest scored one.
int MovePicker::find_best_index() {
int bestScore = -10000000, bestIndex = -1;
for (int i = movesPicked; i < numOfMoves; i++)
if (moves[i].score > bestScore)
{
bestIndex = i;
bestScore = moves[i].score;
}
return bestIndex;
}
@@ -435,8 +433,8 @@ Move MovePicker::pick_move_from_list() {
}
/// MovePicker::current_move_type() returns the type of the just
/// picked next move. It can be used in search to further differentiate
/// MovePicker::current_move_type() returns the type of the just
/// picked next move. It can be used in search to further differentiate
/// according to the current move type: capture, non capture, escape, etc.
MovePicker::MovegenPhase MovePicker::current_move_type() const {