]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/performance-scheme.cc
replace SCM_ASSERT_TYPE with LY_ASSERT_TYPE and friends
[lilypond.git] / lily / performance-scheme.cc
index 3f45829882b8b174e73f99bb077973333800850e..a09904e1e7649af84c58d9b7dfcc7e5ef0a3d983 100644 (file)
@@ -12,12 +12,10 @@ LY_DEFINE (ly_performance_write, "ly:performance-write",
           2, 0, 0, (SCM performance, SCM filename),
           "Write @var{performance} to @var{filename}")
 {
-  Performance *perf = dynamic_cast<Performance *> (unsmob_music_output (performance));
+  LY_ASSERT_FIRST_TYPE (unsmob_performance, performance);
+  LY_ASSERT_TYPE(scm_is_string, 2);
 
-  SCM_ASSERT_TYPE (perf, performance, SCM_ARG1, __FUNCTION__, "Performance");
-  SCM_ASSERT_TYPE (scm_is_string (filename), filename, SCM_ARG2, __FUNCTION__, "file name");
-
-  perf->write_output (ly_scm2string (filename));
+  unsmob_performance (performance)->write_output (ly_scm2string (filename));
   return SCM_UNSPECIFIED;
 }