Han-Wen Nienhuys <[EMAIL PROTECTED]> writes:

> it is cleaner; it is a little bit longer, but it fits exactly within
> the existing patterns.  I would use Text_interface::markup_p 
> for 
>
>>        if (scm_car (s) == Music_type_p_proc)
>>      str += "music";
>> -      else if (ly_c_procedure_p (scm_car (s)))
>> -    str += "scm";
>> +      else if (ly_c_procedure_p (scm_car (s))) 
>> +    {
>> +      if (ly_c_equal_p (scm_car (s), scm_primitive_eval (ly_symbol2scm 
>> ("markup?"))))
>> +        str += "markup";
>> +      else
>> +        str += "scm";
>> +    }
>
> just add another
>
>      else if
>
> before
>
>       else if  (ly_c_procedure_p (. .))

Do you mean:

      if (scm_car (s) == Music_type_p_proc)
        str += "music";
      else if (Text_interface::markup_p (scm_car (s))) 
        str += "markup";
      else if (ly_c_procedure_p (scm_car (s))) 
        str += "scm";

As `s' is just a list of predicates, eg '(markup? ly:music?),
Text_interface::markup_p (markup?) will always be false, no?

nicolas



_______________________________________________
lilypond-devel mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to