diff mbox series

[v3,11/11] sequencer: restrict scope of a formerly public function

Message ID aae9323b25fa9cdd69dcde278f9ac2c60539f153.1631048713.git.gitgitgadget@gmail.com (mailing list archive)
State Accepted
Commit 17919c3585ba9df9c65ea4a5f7300543dfba5f9f
Headers show
Series Drop support for git rebase --preserve-merges | expand

Commit Message

Johannes Schindelin Sept. 7, 2021, 9:05 p.m. UTC
From: Johannes Schindelin <johannes.schindelin@gmx.de>

The function to add the `exec` commands to the todo list only needed to
be public API because it was not only used internally by the sequencer,
but also by `git rebase --preserve-merges`.

Now that that mode has been removed, we no longer need that function to
be scoped publicly.

Helped-by: Alban Gruin <alban.gruin@gmail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---
 sequencer.c | 4 ++--
 sequencer.h | 2 --
 2 files changed, 2 insertions(+), 4 deletions(-)
diff mbox series

Patch

diff --git a/sequencer.c b/sequencer.c
index 7f07cd00f3f..3cdb20b0743 100644
--- a/sequencer.c
+++ b/sequencer.c
@@ -5387,8 +5387,8 @@  int sequencer_make_script(struct repository *r, struct strbuf *out, int argc,
  * Add commands after pick and (series of) squash/fixup commands
  * in the todo list.
  */
-void todo_list_add_exec_commands(struct todo_list *todo_list,
-				 struct string_list *commands)
+static void todo_list_add_exec_commands(struct todo_list *todo_list,
+					struct string_list *commands)
 {
 	struct strbuf *buf = &todo_list->buf;
 	size_t base_offset = buf->len;
diff --git a/sequencer.h b/sequencer.h
index d57d8ea23d7..60a156ea906 100644
--- a/sequencer.h
+++ b/sequencer.h
@@ -160,8 +160,6 @@  int sequencer_remove_state(struct replay_opts *opts);
 int sequencer_make_script(struct repository *r, struct strbuf *out, int argc,
 			  const char **argv, unsigned flags);
 
-void todo_list_add_exec_commands(struct todo_list *todo_list,
-				 struct string_list *commands);
 int complete_action(struct repository *r, struct replay_opts *opts, unsigned flags,
 		    const char *shortrevisions, const char *onto_name,
 		    struct commit *onto, const struct object_id *orig_head,