2018-01-16 0:44 GMT+03:00 Jeff King <peff@xxxxxxxx>: > On Wed, Jan 10, 2018 at 09:36:41AM +0000, Olga Telezhnaya wrote: > >> Need that for further reusing of formatting logic in cat-file. >> Have plans to get rid of using expand_data in cat-file at all, >> and use it only in ref-filter for collecting, formatting and printing >> needed data. > > I think some of these will want to remain in cat-file.c. For instance, > split_on_whitespace is not something that ref-filter.c itself would care > about. I'd expect in the endgame for cat-file to keep its own > split_on_whitespace flag, and to set it based on the presence of the > %(rest) flag, which it can check by seeing if the "rest" atom is in the > "used_atom" list after parsing the format. > > -Peff Yes, maybe we will need to leave some part of expand_data variables. But, if it would be only "split_on_whitespace", it's better to make just one flag without any other stuff. Actually, I thought about moving related logic to ref-filter also. Anyway, it's hard to say exact things before we code everything. Do I need to fix commit message and make it more soft? Olga