Hi, On Mon, 23 Jun 2008, Linus Torvalds wrote:Nope, it is not. To keep things _simple_ a callback is not good. Sure, you can work around the limitations of callbacks for aggregation, but the code change looks horrible. And the same holds true for the help message. Just compare that to the recursive approach. Okay, now for the "granted, your approach has merits" part. That is a totally independent issue from the one I discussed, namely sane handling of the diff (and rev) options. We do have PARSE_OPT_STOP_AT_NON_OPTION since a0ec9d25(parseopt: add flag to stop on first non option), which tries to solve a _similar_ problem, and it should be not hard at all to get PARSE_OPT_STOP_AT_UNKNOWN without changing the loop as you suggested. Heck, we could just as easily introduce PARSE_OPT_IGNORE_UNKNOWN. And here I disagree. You might not need a nice "--help" output, but most mortals do. And this is not easy with your approach. In contrast, by using my approach of having an option_table for a bundle of common options, which just set variables in a certain struct, you can have a relatively painless migration, and you get all the benefits of parse-options. But I guess the approach of whoever has more time to work on it will win... ;-) Ciao, Dscho -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
| Ingo Molnar | [git pull] x86 arch updates for v2.6.25 |
| Greg Kroah-Hartman | [PATCH 02/46] sysfs: crash debugging |
| Chuck Ebbert | Why do so many machines need "noapic"? |
| Greg KH | Re: [BUG] 2.6.24-git usb reset problems |
git: | |
| Wink Saville | Resolving conflicts |
| Andreas Ericsson | git integration with monodevelop |
| Jon Smirl | ! [rejected] master -> master (non-fast forward) |
| Nicolas Bock | error: cannot lock ref 'refs/remotes/origin/*' |
| GVG GVG | ssh_exchange_identification: Connection closed by remote host |
| Christian Weisgerber | Re: libiconv problem |
| Daniel Ouellet | identifying sparse files and get ride of them trick available? |
| Richard Stallman | Real men don't attack straw men |
| Dushan Tcholich | Re: ksoftirqd high cpu load on kernels 2.6.24 to 2.6.27-rc1-mm1 |
| Larry McVoy | Re: tcp bw in 2.6 |
| Arjan van de Ven | Re: [GIT]: Networking |
| Jarek Poplawski | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
