[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lilypond-user
Subject:    scheme-function to provide value for \include
From:       Urs Liska <ul () openlilylib ! org>
Date:       2016-06-28 7:23:14
Message-ID: 2d6c7852-cd4f-92ec-1b3d-11c8b0941b35 () openlilylib ! org
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Hi all,

I am surprised that \include refuses to accept a string that isn't
passed literally but through a scheme-function:

\version "2.19.43" givePath = #(define-scheme-function ()()   
"some/path/that/will/probably/not/be/found.ily") #(display (givePath))
\include \givePath

I would of course expect this to fail because it doesn't find the file,
but instead I get:

error: wrong or undefined identifier: `givePath'

\include

\givePath

/tmp/frescobaldi-AbipCK/tmpMjey3N/document.ly:9:10 <1>: error:
Unfinished main input

\include

\givePath

some/path/that/will/probably/not/be/found.ily

This value was found in the table: #<Music function #<procedure #f
()>>fatal error: failed files:
"/tmp/frescobaldi-AbipCK/tmpMjey3N/document.ly"

Am I missing something here, is this expected to fail?

Urs


[Attachment #5 (text/html)]

<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p>Hi all,</p>
    <p>I am surprised that \include refuses to accept a string that isn't passed \
literally but through a scheme-function:</p>  <p>
</p>
    <p>\version "2.19.43"

givePath =
#(define-scheme-function ()()
     "some/path/that/will/probably/not/be/found.ily")

#(display (givePath))

\include \givePath
</p>
    <p>I would of course expect this to fail because it doesn't find the file, but \
instead I get: <meta name="qrichtext" content="1"></p><p><meta \
http-equiv="Content-Type" content="text/html; charset=utf-8"><style type="text/css"> \
p, li { white-space: pre-wrap; } </style>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; \
-qt-block-indent:0; text-indent:0px;"><!--StartFragment--><span style=" \
font-family:'monospace'; font-size:9pt;">error: wrong or undefined identifier: \
`givePath'</span> </p><p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; \
margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" \
font-family:'monospace'; font-size:9pt;">\include </span> </p><p style=" \
margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; \
-qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; \
font-size:9pt;">         \givePath</span> </p><p style=" margin-top:0px; \
margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; \
text-indent:0px;"><a href="1"><span style=" font-family:'monospace'; \
font-size:9pt;">/tmp/frescobaldi-AbipCK/tmpMjey3N/document.ly:9:10</span></a><span \
style=" font-family:'monospace'; font-size:9pt;">: error: Unfinished main \
input</span> </p><p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; \
margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" \
font-family:'monospace'; font-size:9pt;">\include </span> </p><p style=" \
margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; \
-qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; \
font-size:9pt;">         \givePath</span> </p><p style=" margin-top:0px; \
margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; \
text-indent:0px;"><span style=" font-family:'monospace'; font-size:9pt; \
color:#616121;">some/path/that/will/probably/not/be/found.ily</span> </p><p style=" \
margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; \
-qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; \
font-size:9pt;">This value was found in the table: #&lt;Music function #&lt;procedure \
#f ()&gt;&gt;fatal error: failed files: \
"/tmp/frescobaldi-AbipCK/tmpMjey3N/document.ly"</span></p><span style=" \
font-family:'monospace'; font-size:9pt;"> </span></p><p>Am I missing something here, \
is this expected to fail?</p><p>Urs <span style=" font-family:'monospace'; \
font-size:9pt;"></span></p><!--EndFragment--></body></html>



_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic