+ // Add bonus for safe pawn pushes which attacks an enemy piece
+ b = pos.pieces(Us, PAWN) & ~TRank7BB;
+ b = shift_bb<Up>(b | (shift_bb<Up>(b & TRank2BB) & ~pos.pieces()));
+
+ b &= ~pos.pieces()
+ & ~ei.attackedBy[Them][PAWN]
+ & (ei.attackedBy[Us][PAWN] | ~ei.attackedBy[Them][ALL_PIECES]);
+
+ b = (shift_bb<Left>(b) | shift_bb<Right>(b))
+ & pos.pieces(Them)
+ & ~ei.attackedBy[Us][PAWN];
+
+ if(b)
+ score += popcount<Max15>(b) * PawnAttackThreat;
+