On Thu, Mar 2, 2017 at 4:55 PM, Urs Liska <u...@openlilylib.org> wrote: > > > Am 02.03.2017 um 22:28 schrieb caag...@gmail.com: >> Is it possible to convert a symbol (such as `'bes'`) to a pitch (in >> this case `(ly:make-pitch 1 0 0)`)? I know you can do `#{ bes' #}` to >> get a pitch, but that only appears to work for constants. >> >> Or, for a more general question: is there some way to eval() a string >> as Lilypond code?
Where does the string originate? If it is produced by some other programming interface/language, maybe it be easier to adjust your code so that the string is wrapped in something like `\myMusic = { <strings here> }`. What does the input look like? A bunch of strings in a list/array, or one big string as an input file? > > I'm not fully sure what you really want to achieve, but this works: > > { > #(ly:parser-include-string "bes") > } > > and may help you further. > Urs > >> >> _______________________________________________ >> lilypond-user mailing list >> lilypond-user@gnu.org >> https://lists.gnu.org/mailman/listinfo/lilypond-user > > -- > u...@openlilylib.org > https://openlilylib.org > http://lilypondblog.org > > > _______________________________________________ > lilypond-user mailing list > lilypond-user@gnu.org > https://lists.gnu.org/mailman/listinfo/lilypond-user -- Jeffery Shivers jefferyshivers.com soundcloud.com/jefferyshivers _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user