From 3fa7e6a692ebd2051c179894cc2ea319bd5137af Mon Sep 17 00:00:00 2001 From: Odilf Date: Sat, 12 Aug 2023 15:31:14 +0200 Subject: [PATCH] added `REFERENCE_POSITIONS` to `PieceSet` --- barbarosa/src/generic/piece/set.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/barbarosa/src/generic/piece/set.rs b/barbarosa/src/generic/piece/set.rs index 1e17e53..d532591 100644 --- a/barbarosa/src/generic/piece/set.rs +++ b/barbarosa/src/generic/piece/set.rs @@ -45,6 +45,9 @@ impl, const N: usize> PieceSet { /// Alias to [`PieceSetDescriptor::SOLVED`] pub const SOLVED: Self = Self { pieces: P::SOLVED }; + /// Alias to [`PieceSetDescriptor::REFERENCE_POSITIONS`] + pub const REFERENCE_POSITIONS: [P::Position; N] = P::REFERENCE_POSITIONS; + /// Creates a new [`PieceSet`] from an array of pieces. Fails if one of the invariants is /// not upheld. pub fn new(pieces: [P; N]) -> Result> {