/*
This file is part of LilyPond, the GNU music typesetter.
- Copyright (C) 2005--2014 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ Copyright (C) 2005--2015 Han-Wen Nienhuys <hanwen@xs4all.nl>
LilyPond is free software: you can redistribute it and/or modify
if (Simple_closure *sc = Simple_closure::unsmob (expr))
{
SCM inside = sc->expression ();
- SCM proc = is_unpure_pure_container (scm_car (inside))
- ? (pure ? scm_car (inside) : unpure_pure_container_unpure_part (scm_car (inside)))
- : scm_car (inside);
+ SCM proc = !pure && Unpure_pure_container::is_smob (scm_car (inside))
+ ? Unpure_pure_container::unsmob (scm_car (inside))->unpure_part ()
+ : scm_car (inside);
SCM args = scm_cons (delayed_argument,
evaluate_args (delayed_argument, scm_cdr (inside),
pure, start, end));
return expr;
else if (scm_car (expr) == ly_symbol2scm ("quote"))
return scm_cadr (expr);
- else if (is_unpure_pure_container (scm_car (expr))
+ else if (Unpure_pure_container::is_smob (scm_car (expr))
|| ly_is_procedure (scm_car (expr)))
{
- SCM proc = is_unpure_pure_container (scm_car (expr))
- ? (pure ? scm_car (expr) : unpure_pure_container_unpure_part (scm_car (expr)))
- : scm_car (expr);
+ SCM proc = !pure && Unpure_pure_container::is_smob (scm_car (expr))
+ ? Unpure_pure_container::unsmob (scm_car (expr))->unpure_part ()
+ : scm_car (expr);
SCM args = evaluate_args (delayed_argument, scm_cdr (expr), pure, start, end);
if (args == SCM_UNSPECIFIED)
return SCM_UNSPECIFIED;
}
int
-Simple_closure::print_smob (SCM s, SCM port, scm_print_state *)
+Simple_closure::print_smob (SCM port, scm_print_state *)
{
scm_puts ("#<simple-closure ", port);
- scm_display (scm_cdr (s), port);
+ scm_display (expression (), port);
scm_puts (" >", port);
return 1;
}