Skip to content
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
8 changes: 4 additions & 4 deletions .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ SpaceAfterCStyleCast: true
PenaltyReturnTypeOnItsOwnLine: 240
AttributeMacros:
ForEachMacros:
- GGL_LIST_FOREACH
- GGL_MAP_FOREACH
- GGL_BUF_LIST_FOREACH
- GG_LIST_FOREACH
- GG_MAP_FOREACH
- GG_BUF_LIST_FOREACH
Macros:
- CBMC_CONTRACT(x)=[[cbmc::contract(x)]]
- NODISCARD=[[nodiscard]]
- GGL_EXPORT=[[gnu::visibility(protected)]]
- GG_EXPORT=[[gnu::visibility(protected)]]
- VISIBILITY(x)=[[gnu::visibility(x)]]
- FORMAT(x,y,z)=[[gnu::format(x,y,z)]]
- UNUSED=[[gnu::unused]]
Expand Down
2 changes: 1 addition & 1 deletion src/list.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include <gg/object.h>

GgError gg_list_type_check(GgList list, GgObjectType type) {
GG_LIST_FOREACH(elem, list) {
GG_LIST_FOREACH (elem, list) {
if (gg_obj_type(*elem) != type) {
GG_LOGE("List element is of invalid type.");
return GG_ERR_PARSE;
Expand Down
2 changes: 1 addition & 1 deletion src/map.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ GgObject *gg_kv_val(GgKV *kv) {
}

bool gg_map_get(GgMap map, GgBuffer key, GgObject **result) {
GG_MAP_FOREACH(pair, map) {
GG_MAP_FOREACH (pair, map) {
if (gg_buffer_eq(key, gg_kv_key(*pair))) {
if (result != NULL) {
*result = gg_kv_val(pair);
Expand Down
2 changes: 1 addition & 1 deletion src/vector.c
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ void gg_buf_vec_chain_push(GgError *err, GgBufVec *vector, GgBuffer buf) {
}

GgError gg_buf_vec_append_list(GgBufVec *vector, GgList list) {
GG_LIST_FOREACH(item, list) {
GG_LIST_FOREACH (item, list) {
if (gg_obj_type(*item) != GG_TYPE_BUF) {
return GG_ERR_INVALID;
}
Expand Down