diff --git a/config/config.json b/config/config.json index b2559b27..63623672 100644 --- a/config/config.json +++ b/config/config.json @@ -351,6 +351,9 @@ }, { "file": "libcrux_hacl_glue.c" + }, + { + "file": "core.c" } ] }, diff --git a/libcrux/include/eurydice_glue.h b/libcrux/include/eurydice_glue.h index c791aed1..747f883f 100644 --- a/libcrux/include/eurydice_glue.h +++ b/libcrux/include/eurydice_glue.h @@ -1,6 +1,13 @@ #pragma once -#include "lowstar_endianness.h" +#include +#include +#include +#include +#include + +#include "krml/lowstar_endianness.h" +#include "krml/internal/target.h" // SLICES, ARRAYS, ETC. @@ -78,8 +85,6 @@ static inline void core_ops_arith__i32_319__add_assign(int32_t *x0, int32_t *x1) static inline uint8_t Eurydice_bitand_pv_u8(uint8_t *p, uint8_t v) { return (*p) & v; } static inline uint8_t Eurydice_shr_pv_u8(uint8_t *p, int32_t v) { return (*p) >> v; } -static uint32_t core_num__u32_8__BITS = 32; - // ITERATORS #define core_num_nonzero_NonZeroUsize size_t diff --git a/libcrux/include/internal/core.h b/libcrux/include/internal/core.h index b80977df..18ce9534 100644 --- a/libcrux/include/internal/core.h +++ b/libcrux/include/internal/core.h @@ -28,7 +28,7 @@ static inline uint16_t core_num__u16_7__wrapping_add(uint16_t x0, uint16_t x1); static inline uint8_t core_num__u8_6__wrapping_sub(uint8_t x0, uint8_t x1); -static uint32_t core_num__u32_8__BITS; +#define core_num__u32_8__BITS 32 typedef struct core_option_Option__uint32_t_s {