Thread (1 message) 1 message, 1 author, 2016-06-15

Re: [PATCH/RFC] gitweb: Make git_print_log generic; git_print_simplified_log uses it

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:42:38

Jakub Narebski [off-list ref] writes:
The RFC is about style of git_print_log function. Is it a good idea
and good implementation to pass miscelaneus options as hash values
instead of using fixed order of parameters, and passing 1 or undef?
Is it a good naming of parameters like '-remove_title', or would
'remove_title' or 'remove-title' be better?
I do not personally like the line-noise sub prototypes, since I
have not seen it buys you much in real programs.  Although some
cute hacks like rolling your own control structure lookalikes
cannot be done without them, they are just that -- cute hacks --
and tends to obfuscate what is really happening behind the scene
(not that writing anything in Perl is not already obfuscating
things ;-)).  But maybe it is just me.

I think you already use CGI.pm and the argument passing style
using things like "-remove_title" is the norm there, so I do not
have objections against it.  You might even be able to lift the
code CGI.pm uses to implement the hash-style passing with
defaults.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help