]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/context-mod.cc
lilypond-manuals.css: edit color scheme and some spacing
[lilypond.git] / lily / context-mod.cc
index 460d18bcfd79222ae0c138f798899a3746e3dfdb..892d692bbf8f6c2a89ff1d7288929cf8a8891e95 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 2010--2012 Reinhold Kainhofer <reinhold@kainhofer.com>
+  Copyright (C) 2010--2015 Reinhold Kainhofer <reinhold@kainhofer.com>
 
   LilyPond is free software: you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
@@ -34,30 +34,21 @@ Context_mod::Context_mod (SCM mod_list)
   mods_ = scm_reverse (mod_list);
 }
 
-#include "ly-smobs.icc"
-IMPLEMENT_SIMPLE_SMOBS (Context_mod);
-IMPLEMENT_DEFAULT_EQUAL_P (Context_mod);
-IMPLEMENT_TYPE_P (Context_mod, "ly:context-mod?");
+const char * const Context_mod::type_p_name_ = "ly:context-mod?";
 
 int
-Context_mod::print_smob (SCM smob, SCM port, scm_print_state *)
+Context_mod::print_smob (SCM port, scm_print_state *) const
 {
-  Context_mod *me = (Context_mod *) SCM_CELL_WORD_1 (smob);
-
   scm_puts ("#<Context_mod ", port);
-  scm_display (me->get_mods (), port);
+  scm_display (get_mods (), port);
   scm_puts (">", port);
   return 1;
 }
 
 SCM
-Context_mod::mark_smob (SCM smob)
+Context_mod::mark_smob () const
 {
-  ASSERT_LIVE_IS_ALLOWED ();
-
-  Context_mod *me = (Context_mod *) SCM_CELL_WORD_1 (smob);
-
-  return me->mods_;
+  return mods_;
 }
 
 void
@@ -78,4 +69,3 @@ Context_mod::get_mods () const
 {
   return scm_reverse (mods_);
 }
-