Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clang-format #271

Merged
merged 1 commit into from
Nov 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions lib/host_instance.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,15 @@ struct host_func {

#define HOST_FUNC_PREFIX(FUNC_PREFIX, NAME, TYPE) \
{ \
.name = NAME_FROM_CSTR_LITERAL(#NAME), .type = TYPE, \
.name = NAME_FROM_CSTR_LITERAL(#NAME), \
.type = TYPE, \
.func = FUNC_PREFIX##NAME, \
}

#define HOST_FUNC(NAME, FUNC, TYPE) \
{ \
.name = NAME_FROM_CSTR_LITERAL(NAME), .type = TYPE, \
.name = NAME_FROM_CSTR_LITERAL(NAME), \
.type = TYPE, \
.func = FUNC, \
}

Expand Down
3 changes: 2 additions & 1 deletion lib/module.c
Original file line number Diff line number Diff line change
Expand Up @@ -1958,7 +1958,8 @@ enum dylink_subsection_type {

#define DYLINK_TYPE(NAME) \
{ \
.type = WASM_dylink_##NAME, .name = #NAME, \
.type = WASM_dylink_##NAME, \
.name = #NAME, \
.read = read_dylink_##NAME, \
}

Expand Down
3 changes: 2 additions & 1 deletion lib/module_writer.c
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,8 @@ write_section(struct writer *w, uint8_t id,

#define SECTION(n) \
{ \
.id = SECTION_ID_##n, .write = write_##n##_section, \
.id = SECTION_ID_##n, \
.write = write_##n##_section, \
}

const static struct section {
Expand Down
6 changes: 4 additions & 2 deletions lib/type.h
Original file line number Diff line number Diff line change
Expand Up @@ -391,12 +391,14 @@ struct name {

#define NAME_FROM_CSTR_LITERAL(C) \
{ \
.nbytes = sizeof(C) - 1, .data = C, \
.nbytes = sizeof(C) - 1, \
.data = C, \
}

#define NAME_FROM_CSTR(C) \
{ \
.nbytes = strlen(C), .data = C, \
.nbytes = strlen(C), \
.data = C, \
}

struct import {
Expand Down
3 changes: 2 additions & 1 deletion libwasi/wasi_path_subr.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ struct path_info {

#define PATH_INITIALIZER \
{ \
NULL, NULL, \
NULL, \
NULL, \
}

struct exec_context;
Expand Down
Loading