{"thread":{"id":"17956","subject":"[PATCH/RFC 4/6] object: add one bit to let creation of private types (OBJ_MAX + n)","startedAt":"2009-02-22T18:06:49Z","lastAt":"2009-02-23T01:47:55Z","messageCount":4,"participants":["Marc-André Lureau","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":6},"messages":[{"id":"105800","messageId":"e29894ca0902221006u77fdaa89s9cc01fb27bffce0b@mail.gmail.com","threadId":"17956","inReplyTo":null,"subject":"[PATCH/RFC 4/6] object: add one bit to let creation of private types (OBJ_MAX + n)","fromName":"Marc-André Lureau","fromEmail":"marcandre.lureau@gmail.com","sentAt":"2009-02-22T18:06:49Z","receivedAt":"2009-02-22T18:06:49Z","isPatch":true,"sender":{"key":"marcandre.lureau@gmail.com","avatar":"https://avatars.githubusercontent.com/u/9381?v=4"},"body":"---\n object.h |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/object.h b/object.h\nindex 89dd0c4..83d3644 100644\n--- a/object.h\n+++ b/object.h\n@@ -21,7 +21,7 @@ struct object_array {\n \t} *objects;\n };\n\n-#define TYPE_BITS   3\n+#define TYPE_BITS   4\n #define FLAG_BITS  27\n\n /*\n-- \n1.6.2.rc1.28.g05ef4.dirty\n"},{"id":"105804","messageId":"7vocwuxrgb.fsf@gitster.siamese.dyndns.org","threadId":"17956","inReplyTo":"e29894ca0902221006u77fdaa89s9cc01fb27bffce0b@mail.gmail.com","subject":"Re: [PATCH/RFC 4/6] object: add one bit to let creation of private types (OBJ_MAX + n)","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-02-22T18:21:56Z","receivedAt":"2009-02-22T18:21:56Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Marc-André Lureau <marcandre.lureau@gmail.com> writes:\n\n> ---\n>  object.h |    2 +-\n>  1 files changed, 1 insertions(+), 1 deletions(-)\n>\n> diff --git a/object.h b/object.h\n> index 89dd0c4..83d3644 100644\n> --- a/object.h\n> +++ b/object.h\n> @@ -21,7 +21,7 @@ struct object_array {\n>  \t} *objects;\n>  };\n>\n> -#define TYPE_BITS   3\n> +#define TYPE_BITS   4\n>  #define FLAG_BITS  27\n\nThis would increase the value of (TYPE_BITS+FLAG_BITS).  We spent a lot of\neffect to keep sizeof(struct object) to absolute minimum, and you need to\nhave a very good reason if you are breaking it.\n"},{"id":"105807","messageId":"e29894ca0902221035s54e005adg586409754966cfcc@mail.gmail.com","threadId":"17956","inReplyTo":"7vocwuxrgb.fsf@gitster.siamese.dyndns.org","subject":"Re: [PATCH/RFC 4/6] object: add one bit to let creation of private types (OBJ_MAX + n)","fromName":"Marc-André Lureau","fromEmail":"marcandre.lureau@gmail.com","sentAt":"2009-02-22T18:35:05Z","receivedAt":"2009-02-22T18:35:05Z","isPatch":true,"sender":{"key":"marcandre.lureau@gmail.com","avatar":"https://avatars.githubusercontent.com/u/9381?v=4"},"body":"Hi\n\nOn Sun, Feb 22, 2009 at 8:21 PM, Junio C Hamano <gitster@pobox.com> wrote:\n> Marc-André Lureau <marcandre.lureau@gmail.com> writes:\n>\n>> ---\n>>  object.h |    2 +-\n>>  1 files changed, 1 insertions(+), 1 deletions(-)\n>>\n>> diff --git a/object.h b/object.h\n>> index 89dd0c4..83d3644 100644\n>> --- a/object.h\n>> +++ b/object.h\n>> @@ -21,7 +21,7 @@ struct object_array {\n>>       } *objects;\n>>  };\n>>\n>> -#define TYPE_BITS   3\n>> +#define TYPE_BITS   4\n>>  #define FLAG_BITS  27\n>\n> This would increase the value of (TYPE_BITS+FLAG_BITS).  We spent a lot of\n> effect to keep sizeof(struct object) to absolute minimum, and you need to\n> have a very good reason if you are breaking it.\n>\n>\n\nOoops. Ok, I should try to think harder how to have my own tag_list. I\nonly store a struct tag or a struct light_tag currently.\n\nOne option is to reuse the struct tag, by adding a \"light\" flag, but I\nam not fond of this idea.\n\nSecond option is to create a custom tag list in builtin-tag.c, not\nreusing object_list. I guess this is better then.  What do you think?\n\nFor example:\n\nstruct tag_list {\n struct object *item;\n int light; /* item is a struct light_tag */\n struct object_list *next;\n}\n\nthanks,\n\n-- \nMarc-André Lureau\nSent from: Helsinki Southern Finland Finland.\n"},{"id":"105834","messageId":"7v3ae5yldg.fsf@gitster.siamese.dyndns.org","threadId":"17956","inReplyTo":"e29894ca0902221035s54e005adg586409754966cfcc@mail.gmail.com","subject":"Re: [PATCH/RFC 4/6] object: add one bit to let creation of private types (OBJ_MAX + n)","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-02-23T01:47:55Z","receivedAt":"2009-02-23T01:47:55Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Marc-André Lureau <marcandre.lureau@gmail.com> writes:\n\n> One option is to reuse the struct tag, by adding a \"light\" flag, but I\n> am not fond of this idea.\n>\n> Second option is to create a custom tag list in builtin-tag.c, not\n> reusing object_list. I guess this is better then.  What do you think?\n\nMy preference is, as was indicated in my reply to 5/6, the latter.\n"}]}