From 903529b7088be1d9d6a56983d006839da687b0cb Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Sat, 15 Jan 2022 10:57:58 -0800 Subject: [PATCH] API BREAK: use a C99 bool for 'Agraphinfo.has_sinkrank' --- CHANGELOG.md | 6 +++--- lib/common/types.h | 2 +- lib/dotgen/rank.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 36317e256..c0beacf66 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -28,9 +28,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 now C99 `bool`s instead of Graphviz-specific `boolean`s. - **Breaking**: The `filled`, `landscape`, and `centered` fields of the `layout_t` struct are now C99 `bool`s instead of Graphviz-specific `boolean`s. -- **Breaking**: The `has_images`, `has_flat_edges`, and `has_sourcerank` fields - of the `Agraphinfo_t` struct are now C99 `bool`s instead of Graphviz-specific - `boolean`s. +- **Breaking**: The `has_images`, `has_flat_edges`, `has_sourcerank`, and + `has_sinkrank` fields of the `Agraphinfo_t` struct are now C99 `bool`s instead + of Graphviz-specific `boolean`s. - **Breaking**: Graphviz headers no longer define the constant `MAXSHORT`. A drop-in replacement is `SHRT_MAX` in the C standard library’s limits.h. - **Breaking**: Graphviz headers no lnger define `NIL` macros. A drop-in diff --git a/lib/common/types.h b/lib/common/types.h index f24df6176..8f860cef0 100644 --- a/lib/common/types.h +++ b/lib/common/types.h @@ -324,7 +324,7 @@ typedef enum {NATIVEFONTS,PSFONTS,SVGFONTS} fontname_kind; /* various flags */ bool has_flat_edges; bool has_sourcerank; - boolean has_sinkrank; + bool has_sinkrank; unsigned char showboxes; fontname_kind fontnames; /* to override mangling in SVG */ diff --git a/lib/dotgen/rank.c b/lib/dotgen/rank.c index 928cc688f..efb0607f3 100644 --- a/lib/dotgen/rank.c +++ b/lib/dotgen/rank.c @@ -719,7 +719,7 @@ static void compile_samerank(graph_t * ug, graph_t * parent_clust) } break; case SINKRANK: - GD_has_sinkrank(clust) = TRUE; /* fall through */ + GD_has_sinkrank(clust) = true; /* fall through */ case MAXRANK: leader = union_all(ug); if (clust != NULL) { -- 2.40.0