[PATCH 00/10] mark private symbols static

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Here are a handful of patches to make symbols that are only used
within a .c file as static.  This is not the kind of changes we
would want to do in the pre-release freeze period, and it is just
for reference.  I may later come back to them after 2.3 final is
tagged.

Note that I did not blindly make everything that _could_ be made
static; the ones I deliberately left untouched are:

 * config.c: this has a lot of git_configset_*() API functions that
   were developed but not yet used (as part of 3/4-way done GSoc
   project that did not fully convert users of the config subsystem
   to these new style functions); making them static merely because
   they are not yet used goes backwards.

 * ewah/* and xdiff/*: I consider these borrowed code, which we
   would want to avoid touching in the same series as our own code.

 * graph.c: graph_next_line() and graph_set_column_colors() are not
   called externally, but I suspect that they are API functions
   waiting for a new caller to appear.

 * line-log.c: range_set_append() is not called externally, but this
   is only because a caller calls range_set_append_unsafe(), its
   sibling, which may want to be cleaned up.

 * refs.c: rollback_packed_refs() is not called externally, but the
   codebase around refs API is in flux and I did not want to add to
   the code churn.

 * strbuf.c: xstrvfmt() is not called externally, but this is a
   reasonable API function to keep; its friend xstrfmt() is used by
   many places.

 * string-list.c: print_string_list() may want to go, but it may
   be useful for debugging, so I kept it in.

 * wrapper.c: rmdir_or_warn() is not used externally, but this is a
   reasonable API function as its friends like unlink_or_warn() that
   are used.


The last patch in the series is very questionable.  Instead of
hiding unused author_ident_sufficiently_given() function (and
possibly removing it), it adds external callers to justify its
existence ;-)


Junio C Hamano (10):
  http.c: make finish_active_slot() and handle_curl_result() static
  line-log.c: make line_log_data_init() static
  prompt.c: remove git_getpass() nobody uses
  revision.c: make save_parents() and free_saved_parents() static
  urlmatch.c: make match_urls() static
  remote.c: make clear_cas_option() static
  shallow.c: make check_shallow_file_for_update() static
  pack-bitmap.c: make pack_bitmap_filename() static
  read-cache.c: make fill/match_stat_data() static
  commit: show "Author:" hint when the ident is not given explicitly

 builtin/commit.c |   6 ++--
 cache.h          |  14 --------
 commit.h         |   1 -
 http.c           |  64 ++++++++++++++++-----------------
 http.h           |   2 --
 line-log.c       |   2 +-
 line-log.h       |   2 --
 pack-bitmap.c    |  28 +++++++--------
 pack-bitmap.h    |   1 -
 prompt.c         |   5 ---
 prompt.h         |   1 -
 read-cache.c     |  14 ++++++--
 remote.c         |   2 +-
 remote.h         |   1 -
 revision.c       | 106 +++++++++++++++++++++++++++++--------------------------
 revision.h       |  12 +++----
 shallow.c        |   2 +-
 urlmatch.c       |   6 ++--
 urlmatch.h       |   1 -
 19 files changed, 127 insertions(+), 143 deletions(-)

-- 
2.3.0-rc0-134-g109a908

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]