Skip to content

Commit

Permalink
Fix benchmark runtime C examples
Browse files Browse the repository at this point in the history
The constr_info_t struct has changed, so these examples must be changed accordingly.
  • Loading branch information
paulcadman committed Jun 15, 2023
1 parent 925d7cb commit e437bc7
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion tests/benchmark/fold/runtime/fold.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define CONSTRS_NUM (BUILTIN_UIDS_NUM + 2)

static constr_info_t juvix_constr_info_array[CONSTRS_NUM] = {
BUILTIN_UIDS_INFO, {"nil"}, {"cons"}};
BUILTIN_UIDS_INFO, {"nil", 0, APP_FIXITY}, {"cons", 0, APP_FIXITY}};

#define UID_NIL FIRST_USER_UID
#define UID_CONS (FIRST_USER_UID + 1)
Expand Down
2 changes: 1 addition & 1 deletion tests/benchmark/mapfold/runtime/mapfold.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define CONSTRS_NUM (BUILTIN_UIDS_NUM + 2)

static constr_info_t juvix_constr_info_array[CONSTRS_NUM] = {
BUILTIN_UIDS_INFO, {"nil"}, {"cons"}};
BUILTIN_UIDS_INFO, {"nil", 0, APP_FIXITY}, {"cons", 0, APP_FIXITY}};

#define UID_NIL FIRST_USER_UID
#define UID_CONS (FIRST_USER_UID + 1)
Expand Down
2 changes: 1 addition & 1 deletion tests/benchmark/mapfun/runtime/mapfun.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define CONSTRS_NUM (BUILTIN_UIDS_NUM + 2)

static constr_info_t juvix_constr_info_array[CONSTRS_NUM] = {
BUILTIN_UIDS_INFO, {"nil"}, {"cons"}};
BUILTIN_UIDS_INFO, {"nil", 0, APP_FIXITY}, {"cons", 0, APP_FIXITY}};

#define UID_NIL FIRST_USER_UID
#define UID_CONS (FIRST_USER_UID + 1)
Expand Down
2 changes: 1 addition & 1 deletion tests/benchmark/mapfun/runtime/mapfun_spec.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define CONSTRS_NUM (BUILTIN_UIDS_NUM + 2)

static constr_info_t juvix_constr_info_array[CONSTRS_NUM] = {
BUILTIN_UIDS_INFO, {"nil"}, {"cons"}};
BUILTIN_UIDS_INFO, {"nil", 0, APP_FIXITY}, {"cons", 0, APP_FIXITY}};

#define UID_NIL FIRST_USER_UID
#define UID_CONS (FIRST_USER_UID + 1)
Expand Down
2 changes: 1 addition & 1 deletion tests/benchmark/mergesort/runtime/mergesort.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define CONSTRS_NUM (BUILTIN_UIDS_NUM + 3)

static constr_info_t juvix_constr_info_array[CONSTRS_NUM] = {
BUILTIN_UIDS_INFO, {"nil"}, {"cons"}, {"pair"}};
BUILTIN_UIDS_INFO, {"nil", 0, APP_FIXITY}, {"cons", 0, APP_FIXITY}, {"pair", 0, APP_FIXITY}};

#define UID_NIL FIRST_USER_UID
#define UID_CONS (FIRST_USER_UID + 1)
Expand Down
2 changes: 1 addition & 1 deletion tests/benchmark/prime/runtime/prime.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define CONSTRS_NUM (BUILTIN_UIDS_NUM + 2)

static constr_info_t juvix_constr_info_array[CONSTRS_NUM] = {
BUILTIN_UIDS_INFO, {"nil"}, {"cons"}};
BUILTIN_UIDS_INFO, {"nil", 0, APP_FIXITY}, {"cons", 0, APP_FIXITY}};

#define UID_NIL FIRST_USER_UID
#define UID_CONS (FIRST_USER_UID + 1)
Expand Down

0 comments on commit e437bc7

Please sign in to comment.