diff --git a/game.nim b/game.nim index ed5b2a9..a295a40 100644 --- a/game.nim +++ b/game.nim @@ -50,7 +50,8 @@ type initialized: bool -proc `[]`*[T](b: var Board, idx: T): var Square = +# use a template here for better inlining +template `[]`*[T](b: var Board, idx: T): var Square = b.squares[idx]