Skip to content

Commit

Permalink
Minor bitboard opt
Browse files Browse the repository at this point in the history
Inline apply method.
  • Loading branch information
isaacl committed Oct 12, 2024
1 parent 81c8e6d commit 7b9f221
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/scala/bitboard/Bitboard.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ opaque type Bitboard = Long
object Bitboard:
import Attacks.*

def apply(l: Long): Bitboard = l
inline def apply(inline l: Long): Bitboard = l
inline def apply(inline xs: Iterable[Square]): Bitboard = xs.foldLeft(empty)((b, s) => b | s.bl)
inline def apply(xs: Square*): Bitboard = apply(xs.toList)

Expand Down

0 comments on commit 7b9f221

Please sign in to comment.