aboutsummaryrefslogtreecommitdiff
path: root/src/core/moves.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/moves.h')
-rw-r--r--src/core/moves.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/core/moves.h b/src/core/moves.h
index 8f91167..7e80946 100644
--- a/src/core/moves.h
+++ b/src/core/moves.h
@@ -21,7 +21,7 @@ STATIC uint8_t inverse_move(uint8_t);
21STATIC void sortparallel_moves(size_t n, uint8_t [n]); 21STATIC void sortparallel_moves(size_t n, uint8_t [n]);
22STATIC bool are_lastmoves_singlecw(size_t n, const uint8_t [n]); 22STATIC bool are_lastmoves_singlecw(size_t n, const uint8_t [n]);
23 23
24STATIC cube_t applymoves(cube_t, const char *); 24STATIC oriented_cube_t applymoves(oriented_cube_t, const char *);
25 25
26#define FOREACH_READMOVE(ARG_BUF, ARG_MOVE, ARG_C, ARG_MAX, \ 26#define FOREACH_READMOVE(ARG_BUF, ARG_MOVE, ARG_C, ARG_MAX, \
27 RET_ERROR, ARG_ACTION) \ 27 RET_ERROR, ARG_ACTION) \
@@ -319,17 +319,17 @@ are_lastmoves_singlecw(size_t n, const uint8_t moves[n])
319 return isbase(moves[n-1]) && (!two || isbase(moves[n-2])); 319 return isbase(moves[n-1]) && (!two || isbase(moves[n-2]));
320} 320}
321 321
322STATIC cube_t 322STATIC oriented_cube_t
323applymoves(cube_t cube, const char *buf) 323applymoves(oriented_cube_t cube, const char *buf)
324{ 324{
325 int c; 325 int c;
326 uint8_t m; 326 uint8_t m;
327 327
328 DBG_ASSERT(isconsistent(cube), ZERO_CUBE, 328 DBG_ASSERT(isconsistent(cube), ZERO_ORIENTED_CUBE,
329 "move error: inconsistent cube\n"); 329 "move error: inconsistent cube\n");
330 330
331 FOREACH_READMOVE(buf, m, c, -1, ZERO_CUBE, 331 FOREACH_READMOVE(buf, m, c, -1, ZERO_ORIENTED_CUBE,
332 cube = move(cube, m); 332 cube.cube = move(cube.cube, m);
333 ) 333 )
334 334
335 return cube; 335 return cube;

Generated with cgit - Back to sebastiano.tronto.net