From: Pablo Sabater Date: Mon, 13 Jul 2026 20:51:19 GMT Subject: Re: [PATCH v11 0/7] graph: indent visual roots in graph Message-ID: In-Reply-To: On Mon Jul 13, 2026 at 10:28 PM CEST, Junio C Hamano wrote: > Pablo Sabater writes: > >> V9 DIFF: >> >> - Changed boolean variables to be bit fields. > > v11??? > My bad, I updated it manually and I forgot to. >> >> 7: 737331b68d ! 7: c1fa81022e graph: add --[no-]graph-indent and log.graphIndent >> @@ revision.h: struct rev_info { >> /* Display history graph */ >> struct git_graph *graph; >> int graph_max_lanes; >> -+ int no_graph_indent; >> -+ unsigned int graph_indent_set; >> ++ unsigned int no_graph_indent:1; >> ++ unsigned int graph_indent_set:1; > > OK. References to these occur primarily in a boolean context, and > all assignments to them are either 0 or 1. > > graph.c:442: revs->no_graph_indent = !val; > graph.c:1008: !graph->revs->no_graph_indent; > graph.c:1353: if (graph->is_visual_root && !graph->revs->no_graph_indent) { > revision.c:2630: revs->no_graph_indent = 0; > revision.c:2631: revs->graph_indent_set = 1; > revision.c:2633: revs->no_graph_indent = 1; > revision.c:2634: revs->graph_indent_set = 1; > revision.c:3209: if (revs->graph_indent_set > 0 && !revs->graph) > > You may want to rewrite the last conditional check to: > > if (revs->graph_indent_set && !revs->graph) > > This avoids confusing readers into thinking the member can be set > to 2 or greater. I'll do that. Thanks. > > Thanks. Regards, Pablo.