From 1964938ca6abef6e5c81d9dccdf42c55abacb5e9 Mon Sep 17 00:00:00 2001 From: Sebastiano Tronto Date: Sun, 5 Nov 2023 16:29:14 +0100 Subject: Refactoring --- utils/genmovecode.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'utils/genmovecode.sh') diff --git a/utils/genmovecode.sh b/utils/genmovecode.sh index c389ea8..688ee39 100755 --- a/utils/genmovecode.sh +++ b/utils/genmovecode.sh @@ -2,16 +2,16 @@ type="${1:-src}" -gcc -DDEBUG h48_to_"$type".c ../src/cube.c -o h48_to_"$type" +gcc -DDEBUG h48_to_"$type".c ../cube.c -o h48_to_"$type" genfuncs() { for f in move_??_*.txt; do move="$(echo $f | sed 's/.*_// ; s/\.txt//')" - printf 'static inline cube_t\ninline_move_%s' "$move" + printf 'static inline cube_t\n_move_%s' "$move" printf '(cube_t c)\n{\n' printf '\tcube_t m = ' ./h48_to_"$type" <"$f" | sed '2,4s/^/\t/' - printf ';\n\n\treturn compose(c, m);\n}\n\n' + printf ';\n\n\treturn _compose(c, m);\n}\n\n' done } -- cgit v1.3