diff --git a/cbits/goldilocks.c b/goldilocks_hash/cbits/goldilocks.c similarity index 100% rename from cbits/goldilocks.c rename to goldilocks_hash/cbits/goldilocks.c diff --git a/cbits/goldilocks.h b/goldilocks_hash/cbits/goldilocks.h similarity index 100% rename from cbits/goldilocks.h rename to goldilocks_hash/cbits/goldilocks.h diff --git a/cbits/monolith_constants.inc b/goldilocks_hash/cbits/monolith_constants.inc similarity index 100% rename from cbits/monolith_constants.inc rename to goldilocks_hash/cbits/monolith_constants.inc diff --git a/cbits/monolith_conv_uint64.inc b/goldilocks_hash/cbits/monolith_conv_uint64.inc similarity index 100% rename from cbits/monolith_conv_uint64.inc rename to goldilocks_hash/cbits/monolith_conv_uint64.inc diff --git a/cbits/poseidon2_constants.inc b/goldilocks_hash/cbits/poseidon2_constants.inc similarity index 100% rename from cbits/poseidon2_constants.inc rename to goldilocks_hash/cbits/poseidon2_constants.inc diff --git a/goldilocks_hash/goldilocks.nim b/goldilocks_hash/goldilocks.nim index 37c0111..b7ecc08 100644 --- a/goldilocks_hash/goldilocks.nim +++ b/goldilocks_hash/goldilocks.nim @@ -1,11 +1,11 @@ -{. compile: "../cbits/goldilocks.c" .} +{. compile: "../goldilocks_hash/cbits/goldilocks.c" .} import ./types -func neg* (x: F ): F {. header: "../cbits/goldilocks.h", importc: "goldilocks_neg", cdecl .} -func `+`* (x, y: F): F {. header: "../cbits/goldilocks.h", importc: "goldilocks_add", cdecl .} -func `-`* (x, y: F): F {. header: "../cbits/goldilocks.h", importc: "goldilocks_sub", cdecl .} -func `*`* (x, y: F): F {. header: "../cbits/goldilocks.h", importc: "goldilocks_mul", cdecl .} +func neg* (x: F ): F {. header: "../goldilocks_hash/cbits/goldilocks.h", importc: "goldilocks_neg", cdecl .} +func `+`* (x, y: F): F {. header: "../goldilocks_hash/cbits/goldilocks.h", importc: "goldilocks_add", cdecl .} +func `-`* (x, y: F): F {. header: "../goldilocks_hash/cbits/goldilocks.h", importc: "goldilocks_sub", cdecl .} +func `*`* (x, y: F): F {. header: "../goldilocks_hash/cbits/goldilocks.h", importc: "goldilocks_mul", cdecl .} proc `+=`* (x: var F, y: F) = x = x + y proc `-=`* (x: var F, y: F) = x = x - y