{"thread":{"id":"9914","subject":"[PATCH 5/5] Use 'unsigned:1' when we mean boolean options","startedAt":"2007-09-18T08:55:00Z","lastAt":"2007-09-18T08:55:00Z","messageCount":1,"participants":["Shawn O. Pearce"],"isPatch":true,"patchVersion":1,"patchTotal":5},"messages":[{"id":"53420","messageId":"20070918085500.GE5390@spearce.org","threadId":"9914","inReplyTo":null,"subject":"[PATCH 5/5] Use 'unsigned:1' when we mean boolean options","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2007-09-18T08:55:00Z","receivedAt":"2007-09-18T08:55:00Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"These options are all strictly boolean (true/false).  Its easier to\ndocument this implicitly by making their storage type a single bit.\nThere is no compelling memory space reduction reason for this change,\nit just makes the structure definition slightly more readable.\n\nSigned-off-by: Shawn O. Pearce <spearce@spearce.org>\n---\n fetch-pack.h |   12 ++++++------\n 1 files changed, 6 insertions(+), 6 deletions(-)\n\ndiff --git a/fetch-pack.h b/fetch-pack.h\nindex cdcd84f..ad13076 100644\n--- a/fetch-pack.h\n+++ b/fetch-pack.h\n@@ -4,14 +4,14 @@\n struct fetch_pack_args\n {\n \tconst char *uploadpack;\n-\tint quiet;\n-\tint keep_pack;\n \tint unpacklimit;\n-\tint use_thin_pack;\n-\tint fetch_all;\n-\tint verbose;\n \tint depth;\n-\tint no_progress;\n+\tunsigned quiet:1,\n+\t\tkeep_pack:1,\n+\t\tuse_thin_pack:1,\n+\t\tfetch_all:1,\n+\t\tverbose:1,\n+\t\tno_progress:1;\n };\n \n void setup_fetch_pack(struct fetch_pack_args *args);\n-- \n1.5.3.1.1000.g7319b\n"}]}