Ramkumar Ramachandra [off-list ref] writes:
quoted hunk
diff --git a/builtin/revert.c b/builtin/revert.c
index 5c0b97e..eb68068 100644
--- a/builtin/revert.c
+++ b/builtin/revert.c
@@ -46,6 +46,9 @@ enum replay_action { REVERT, CHERRY_PICK };
struct replay_opts {
enum replay_action action;
+ /* --skip-all */
+ int skipall_oper;
Yikes what is that "oper" doing there? Don't truncate a word in the
middle only to shorten names and make it unclear what you want to say. Is
that operand? operation? In this case, I think "int skip_all" is
sufficient, and you can lose the comment that adds no extra information.
Hi Junio,
Junio C Hamano writes:
Ramkumar Ramachandra [off-list ref] writes:
quoted
diff --git a/builtin/revert.c b/builtin/revert.c
index 5c0b97e..eb68068 100644
--- a/builtin/revert.c
+++ b/builtin/revert.c
@@ -46,6 +46,9 @@ enum replay_action { REVERT, CHERRY_PICK }; struct replay_opts {
enum replay_action action;
+ /* --skip-all */
+ int skipall_oper;
Yikes what is that "oper" doing there? Don't truncate a word in the
middle only to shorten names and make it unclear what you want to say. Is
that operand? operation? In this case, I think "int skip_all" is
sufficient, and you can lose the comment that adds no extra information.
Interesting side note: I'd initially wanted to use "skip_all" and
"continue", but "continue" is a C keyword. That's why I'd reluctantly
suffixed "_oper" to both for consistency.
-- Ram
Ramkumar Ramachandra [off-list ref] writes:
Interesting side note: I'd initially wanted to use "skip_all" and
"continue", but "continue" is a C keyword. That's why I'd reluctantly
suffixed "_oper" to both for consistency.
It seems a good idea to restrict such uglification to only those cases
where it's necessary, not make _everything_ ugly just for the sake of
consistency.....
[The traditional thing to do with C-keyword conflicts, when there's no
obvious and natural alternative, seems to just be intentional mispelling
-- "continu", "kontinue", "cont", "_continue", whatever. Yes, they're
ugly, but people will know why you did it, and they'll forgive you.]
-Miles
--
Helpmate, n. A wife, or bitter half.
Hi Miles,
Miles Bader writes:
Ramkumar Ramachandra [off-list ref] writes:
quoted
Interesting side note: I'd initially wanted to use "skip_all" and
"continue", but "continue" is a C keyword. That's why I'd reluctantly
suffixed "_oper" to both for consistency.
It seems a good idea to restrict such uglification to only those cases
where it's necessary, not make _everything_ ugly just for the sake of
consistency.....
[The traditional thing to do with C-keyword conflicts, when there's no
obvious and natural alternative, seems to just be intentional mispelling
-- "continu", "kontinue", "cont", "_continue", whatever. Yes, they're
ugly, but people will know why you did it, and they'll forgive you.]
Interesting. Are there such examples in the Git codebase as well?
-- Ram