2011-04-14 Paul Eggert <eggert@cs.ucla.edu>
+ Don't publish debugger-only interfaces to other modules.
+ * lisp.h (safe_debug_print, debug_output_compilation_hack):
+ (verify_bytepos, count_markers): Move decls to the only modules
+ that need them.
+ * region-cache.h (pp_cache): Likewise.
+ * window.h (check_all_windows): Likewise.
+ * marker.c, print.c, region-cache.c, window.c: Decls moved here.
+
* sysdep.c (croak): Now static, if
defined TIOCNOTTY || defined USG5 || defined CYGWIN.
* syssignal.h (croak): Declare only if not static.
/* Defined in print.c */
extern Lisp_Object Vprin1_to_string_buffer;
extern void debug_print (Lisp_Object) EXTERNALLY_VISIBLE;
-extern void safe_debug_print (Lisp_Object) EXTERNALLY_VISIBLE;
EXFUN (Fprin1, 2);
EXFUN (Fprin1_to_string, 2);
EXFUN (Fterpri, 1);
EXFUN (Ferror_message_string, 1);
extern Lisp_Object Qstandard_output;
extern Lisp_Object Qexternal_debugging_output;
-extern void debug_output_compilation_hack (int) EXTERNALLY_VISIBLE;
extern void temp_output_buffer_setup (const char *);
extern int print_level;
extern Lisp_Object Qprint_escape_newlines;
extern void clear_charpos_cache (struct buffer *);
extern EMACS_INT charpos_to_bytepos (EMACS_INT);
extern EMACS_INT buf_charpos_to_bytepos (struct buffer *, EMACS_INT);
-extern EMACS_INT verify_bytepos (EMACS_INT charpos) EXTERNALLY_VISIBLE;
extern EMACS_INT buf_bytepos_to_charpos (struct buffer *, EMACS_INT);
extern void unchain_marker (struct Lisp_Marker *marker);
extern Lisp_Object set_marker_restricted (Lisp_Object, Lisp_Object, Lisp_Object);
extern Lisp_Object set_marker_both (Lisp_Object, Lisp_Object, EMACS_INT, EMACS_INT);
extern Lisp_Object set_marker_restricted_both (Lisp_Object, Lisp_Object,
EMACS_INT, EMACS_INT);
-extern int count_markers (struct buffer *) EXTERNALLY_VISIBLE;
extern void syms_of_marker (void);
/* Defined in fileio.c */
/* Used for debugging: recompute the bytepos corresponding to CHARPOS
in the simplest, most reliable way. */
+extern EMACS_INT verify_bytepos (EMACS_INT charpos) EXTERNALLY_VISIBLE;
EMACS_INT
verify_bytepos (EMACS_INT charpos)
{
/* For debugging -- count the markers in buffer BUF. */
+extern int count_markers (struct buffer *) EXTERNALLY_VISIBLE;
int
count_markers (struct buffer *buf)
{
/* This function is never called. Its purpose is to prevent
print_output_debug_flag from being optimized away. */
+exterr void debug_output_compilation_hack (int) EXTERNALLY_VISIBLE;
void
debug_output_compilation_hack (int x)
{
fprintf (stderr, "\r\n");
}
+void safe_debug_print (Lisp_Object) EXTERNALLY_VISIBLE;
void
safe_debug_print (Lisp_Object arg)
{
\f
/* Debugging: pretty-print a cache to the standard error output. */
+void pp_cache (struct region_cache *) EXTERNALLY_VISIBLE;
void
pp_cache (struct region_cache *c)
{
struct region_cache *CACHE,
EMACS_INT POS,
EMACS_INT *NEXT);
-
-/* For debugging. */
-void pp_cache (struct region_cache *) EXTERNALLY_VISIBLE;
/* Used for debugging. Abort if any window has a dead buffer. */
+extern void check_all_windows (void) EXTERNALLY_VISIBLE;
void
check_all_windows (void)
{
extern void grow_mini_window (struct window *, int);
extern void shrink_mini_window (struct window *);
extern int window_relative_x_coord (struct window *, enum window_part, int);
-extern void check_all_windows (void) EXTERNALLY_VISIBLE;
void run_window_configuration_change_hook (struct frame *f);