From a787177cc3613b03361c6ef50547455922d0b86b Mon Sep 17 00:00:00 2001 From: David Kastrup Date: Sat, 27 Sep 2014 13:56:59 +0200 Subject: [PATCH] Issue 4134: Remove trivial print_smob member functions Those are provided by the Smob_base class anyway. --- lily/book.cc | 7 ------- lily/context-property.cc | 9 --------- lily/include/book.hh | 1 - lily/include/listener.hh | 1 - lily/include/page-marker.hh | 1 - lily/include/paper-book.hh | 1 - lily/include/paper-outputter.hh | 1 - lily/include/score.hh | 1 - lily/include/skyline.hh | 1 - lily/listener.cc | 7 ------- lily/page-marker.cc | 9 --------- lily/paper-book.cc | 9 --------- lily/paper-outputter.cc | 9 --------- lily/score.cc | 8 -------- lily/skyline.cc | 11 ----------- 15 files changed, 76 deletions(-) diff --git a/lily/book.cc b/lily/book.cc index 4c426da4fd..21fb405c85 100644 --- a/lily/book.cc +++ b/lily/book.cc @@ -117,13 +117,6 @@ Book::mark_smob () return header_; } -int -Book::print_smob (SCM, SCM p, scm_print_state *) -{ - scm_puts ("#", p); - return 1; -} - void Book::add_score (SCM s) { diff --git a/lily/context-property.cc b/lily/context-property.cc index 369037381a..7dba9d6e85 100644 --- a/lily/context-property.cc +++ b/lily/context-property.cc @@ -66,7 +66,6 @@ typecheck_grob (SCM symbol, SCM value) class Grob_properties : public Simple_smob { public: - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); static const char type_p_name_[]; private: @@ -106,14 +105,6 @@ Grob_properties::mark_smob () return cooked_from_; } -int -Grob_properties::print_smob (SCM /*smob*/, SCM port, scm_print_state *) -{ - scm_puts ("#", port); - - return 1; -} - LY_DEFINE (ly_make_grob_properties, "ly:make-grob-properties", 1, 0, 0, (SCM alist), "This packages the given property list @var{alist} in" diff --git a/lily/include/book.hh b/lily/include/book.hh index 0910a9b9e7..f74d1d981f 100644 --- a/lily/include/book.hh +++ b/lily/include/book.hh @@ -29,7 +29,6 @@ class Book : public Smob { public: - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); static const char type_p_name_[]; virtual ~Book (); diff --git a/lily/include/listener.hh b/lily/include/listener.hh index 2dfdc0c9f8..959f7e510f 100644 --- a/lily/include/listener.hh +++ b/lily/include/listener.hh @@ -74,7 +74,6 @@ class Listener : public Simple_smob { public: static SCM equal_p (SCM, SCM); - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); static const char type_p_name_[]; private: diff --git a/lily/include/page-marker.hh b/lily/include/page-marker.hh index 57315f5322..9670b68129 100644 --- a/lily/include/page-marker.hh +++ b/lily/include/page-marker.hh @@ -26,7 +26,6 @@ class Page_marker : public Smob { public: - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); static const char type_p_name_[]; virtual ~Page_marker (); diff --git a/lily/include/paper-book.hh b/lily/include/paper-book.hh index c1c8d2267b..716ddd5b3d 100644 --- a/lily/include/paper-book.hh +++ b/lily/include/paper-book.hh @@ -30,7 +30,6 @@ class Paper_book : public Smob { public: - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); static const char type_p_name_[]; virtual ~Paper_book (); diff --git a/lily/include/paper-outputter.hh b/lily/include/paper-outputter.hh index 624ae65a39..e99d21e37f 100644 --- a/lily/include/paper-outputter.hh +++ b/lily/include/paper-outputter.hh @@ -33,7 +33,6 @@ class Paper_outputter : public Smob { public: - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); virtual ~Paper_outputter (); private: diff --git a/lily/include/score.hh b/lily/include/score.hh index f66a81ba62..e282a5e81b 100644 --- a/lily/include/score.hh +++ b/lily/include/score.hh @@ -30,7 +30,6 @@ class Score : public Smob { public: - static int print_smob (SCM, SCM, scm_print_state *); SCM mark_smob (); static const char type_p_name_[]; virtual ~Score (); diff --git a/lily/include/skyline.hh b/lily/include/skyline.hh index dd65bec147..31f6969d5b 100644 --- a/lily/include/skyline.hh +++ b/lily/include/skyline.hh @@ -52,7 +52,6 @@ struct Building class Skyline : public Simple_smob { public: - static int print_smob (SCM, SCM, scm_print_state *); static const char type_p_name_[]; private: list buildings_; diff --git a/lily/listener.cc b/lily/listener.cc index a6dcbd1020..50f1969ecb 100644 --- a/lily/listener.cc +++ b/lily/listener.cc @@ -51,13 +51,6 @@ Listener::mark_smob () return SCM_EOL; } -int -Listener::print_smob (SCM, SCM p, scm_print_state *) -{ - scm_puts ("#", p); - return 1; -} - SCM Listener::equal_p (SCM a, SCM b) { diff --git a/lily/page-marker.cc b/lily/page-marker.cc index f2940d2b76..78b1b2cefe 100644 --- a/lily/page-marker.cc +++ b/lily/page-marker.cc @@ -50,15 +50,6 @@ Page_marker::mark_smob () return SCM_EOL; } -int -Page_marker::print_smob (SCM smob, SCM port, scm_print_state *) -{ - Page_marker *pm = (Page_marker *) SCM_CELL_WORD_1 (smob); - (void) pm; - scm_puts ("#", port); - return 1; -} - SCM Page_marker::permission_symbol () { diff --git a/lily/paper-book.cc b/lily/paper-book.cc index cfc1caf2af..f1423ef3b6 100644 --- a/lily/paper-book.cc +++ b/lily/paper-book.cc @@ -69,15 +69,6 @@ Paper_book::mark_smob () return systems_; } -int -Paper_book::print_smob (SCM smob, SCM port, scm_print_state *) -{ - Paper_book *b = (Paper_book *) SCM_CELL_WORD_1 (smob); - (void)b; - scm_puts ("#", port); - return 1; -} - Output_def * Paper_book::top_paper () { diff --git a/lily/paper-outputter.cc b/lily/paper-outputter.cc index 91bffa2242..3600d1dbfb 100644 --- a/lily/paper-outputter.cc +++ b/lily/paper-outputter.cc @@ -68,15 +68,6 @@ Paper_outputter::mark_smob () return file_; } -int -Paper_outputter::print_smob (SCM /* x */, - SCM p, - scm_print_state *) -{ - scm_puts ("#", p); - return 1; -} - SCM Paper_outputter::file () const { diff --git a/lily/score.cc b/lily/score.cc index b1659e2fbb..88d87e9aeb 100644 --- a/lily/score.cc +++ b/lily/score.cc @@ -72,14 +72,6 @@ Score::mark_smob () return music_; } -int -Score::print_smob (SCM, SCM p, scm_print_state *) -{ - scm_puts ("#", p); - - return 1; -} - Score::Score (Score const &s) { header_ = SCM_EOL; diff --git a/lily/skyline.cc b/lily/skyline.cc index 40e43ab9ef..36cceceb8e 100644 --- a/lily/skyline.cc +++ b/lily/skyline.cc @@ -863,17 +863,6 @@ Skyline::clear () const char Skyline::type_p_name_[] = "ly:skyline?"; -int -Skyline::print_smob (SCM s, SCM port, scm_print_state *) -{ - Skyline *r = (Skyline *) SCM_CELL_WORD_1 (s); - (void) r; - - scm_puts ("#", port); - - return 1; -} - MAKE_SCHEME_CALLBACK_WITH_OPTARGS (Skyline, get_touching_point, 3, 1, "") SCM Skyline::get_touching_point (SCM skyline_scm, SCM other_skyline_scm, SCM horizon_padding_scm) -- 2.39.2