void
Context_def::add_context_mod (SCM mod)
{
- SCM tag = ly_car (mod);
+ SCM tag = scm_car (mod);
if (ly_symbol2scm ("description") == tag)
{
- description_ = ly_cadr (mod);
+ description_ = scm_cadr (mod);
return;
}
- SCM sym = ly_cadr (mod);
+ SCM sym = scm_cadr (mod);
if (scm_is_string (sym))
sym = scm_string_to_symbol (sym);
{
SCM mods = scm_reverse_x (scm_list_copy (accept_mods_), user_mod);
SCM acc = SCM_EOL;
- for (SCM s = mods; ly_c_pair_p (s); s = ly_cdr (s))
+ for (SCM s = mods; scm_is_pair (s); s = scm_cdr (s))
{
- SCM tag = ly_caar (s);
- SCM sym = ly_cadar (s);
+ SCM tag = scm_caar (s);
+ SCM sym = scm_cadar (s);
if (tag == ly_symbol2scm ("accepts"))
acc = scm_cons (sym, acc);
else if (tag == ly_symbol2scm ("denies"))
Link_array<Context_def>
Context_def::path_to_acceptable_context (SCM type_sym, Output_def *odef) const
{
- assert (ly_c_symbol_p (type_sym));
+ assert (scm_is_symbol (type_sym));
SCM accepted = get_accepted (SCM_EOL);
Link_array<Context_def> accepteds;
- for (SCM s = accepted; ly_c_pair_p (s); s = ly_cdr (s))
+ for (SCM s = accepted; scm_is_pair (s); s = scm_cdr (s))
if (Context_def *t = unsmob_context_def (find_context_def (odef,
- ly_car (s))))
+ scm_car (s))))
accepteds.push (t);
Link_array<Context_def> best_result;
SCM mods = scm_reverse_x (scm_list_copy (translator_mods_), user_mod);
- for (SCM s = mods; ly_c_pair_p (s); s = ly_cdr (s))
+ for (SCM s = mods; scm_is_pair (s); s = scm_cdr (s))
{
- SCM tag = ly_caar (s);
- SCM arg = ly_cadar (s);
+ SCM tag = scm_caar (s);
+ SCM arg = scm_cadar (s);
if (scm_is_string (arg))
arg = scm_string_to_symbol (arg);
SCM
filter_performers (SCM ell)
{
- for (SCM *tail = ℓ ly_c_pair_p (*tail); tail = SCM_CDRLOC (*tail))
+ for (SCM *tail = ℓ scm_is_pair (*tail); tail = SCM_CDRLOC (*tail))
{
- if (dynamic_cast<Performer*> (unsmob_translator (ly_car (*tail))))
+ if (dynamic_cast<Performer*> (unsmob_translator (scm_car (*tail))))
{
- *tail = ly_cdr (*tail);
- if (!ly_c_pair_p (*tail))
+ *tail = scm_cdr (*tail);
+ if (!scm_is_pair (*tail))
break ;
}
}
filter_engravers (SCM ell)
{
SCM *tail = ℓ
- for (; ly_c_pair_p (*tail) ; tail = SCM_CDRLOC (*tail))
+ for (; scm_is_pair (*tail) ; tail = SCM_CDRLOC (*tail))
{
- if (dynamic_cast<Engraver*> (unsmob_translator (ly_car (*tail))))
+ if (dynamic_cast<Engraver*> (unsmob_translator (scm_car (*tail))))
{
- *tail = ly_cdr (*tail);
- if (!ly_c_pair_p (*tail))
+ *tail = scm_cdr (*tail);
+ if (!scm_is_pair (*tail))
break ;
}
}
SCM trans_names = get_translator_names (ops);
- Translator *g = get_translator (translator_group_type_);
- g = g->clone ();
+ Translator_group *g = dynamic_cast<Translator_group*>
+ (get_translator (translator_group_type_));
+ g = dynamic_cast<Translator_group*> (g->clone ());
SCM trans_list = SCM_EOL;
- for (SCM s = trans_names; ly_c_pair_p (s) ; s = ly_cdr (s))
+ for (SCM s = trans_names; scm_is_pair (s) ; s = scm_cdr (s))
{
- Translator *t = get_translator (ly_car (s));
+ Translator *t = get_translator (scm_car (s));
if (!t)
warning (_f ("can't find: `%s'", s));
else
if (tr->must_be_last ())
{
SCM cons = scm_cons (str, SCM_EOL);
- if (ly_c_pair_p (trans_list))
+ if (scm_is_pair (trans_list))
scm_set_cdr_x (scm_last_pair (trans_list), cons);
else
trans_list= cons;
ell = scm_cons (scm_cons (ly_symbol2scm ("context-name"), context_name_),
ell);
- if (ly_c_symbol_p (translator_group_type_))
+ if (scm_is_symbol (translator_group_type_))
ell = scm_cons (scm_cons (ly_symbol2scm ("group-type"),
translator_group_type_), ell);
return ell;