I might have spoken too soon, this doesn't seem to work:<br><br>(module foo mzscheme<br><div class="Ih2E3d"> (require (planet "sxml.ss" ("lizorkin" "sxml.plt" 1 4)))<br><br><span style="color: rgb(102, 51, 102);">
(define test</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> (apply</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> string-append</span><br style="color: rgb(102, 51, 102);">
<span style="color: rgb(102, 51, 102);"> (sxml:clean-feed</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> (stx:transform-dynamic</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);">
(sxml:add-parents</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> (sxml:document "</span><a style="color: rgb(102, 51, 102);" href="http://modis.ispras.ru/Lizorkin/XML/poem.xml" target="_blank">
http://modis.ispras.ru/Lizorkin/XML/poem.xml</a><span style="color: rgb(102, 51, 102);">"))</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> (stx:make-stx-stylesheet</span><br style="color: rgb(102, 51, 102);">
<span style="color: rgb(102, 51, 102);"> (sxml:document</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> "</span><a style="color: rgb(102, 51, 102);" href="http://modis.ispras.ru/Lizorkin/XML/poem2html.xsl" target="_blank">
http://modis.ispras.ru/Lizorkin/XML/poem2html.xsl</a><span style="color: rgb(102, 51, 102);">"</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> '((xsl . "</span><a style="color: rgb(102, 51, 102);" href="http://www.w3.org/1999/XSL/Transform" target="_blank">
http://www.w3.org/1999/XSL/Transform</a><span style="color: rgb(102, 51, 102);">"))))))) ;originaly had a leading space " </span><a style="color: rgb(102, 51, 102);" href="http://www.w3.org/1999/XSL/Transform" target="_blank">
http://www.w3.org/1999/XSL/Transform</a><span style="color: rgb(102, 51, 102);">"</span><br style="color: rgb(102, 51, 102);"><span style="color: rgb(102, 51, 102);"> )</span><br><br></div>(provide test))<br><br><br>
(module foo-user mzscheme<br> (require (file "foo.ss"))<br><br> (display test)<br> )<br><font color="#888888"><br></font><br><br><br><div class="gmail_quote">On Jan 13, 2008 5:41 PM, John Clements <<a href="mailto:clements@brinckerhoff.org">
clements@brinckerhoff.org</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="Ih2E3d"><br>On Jan 12, 2008, at 8:20 PM, Eric Biunno wrote:
<br><br>> Hi, I'm a little confused. The following code works as expected:<br>><br>> (require (planet "sxml.ss" ("lizorkin" "sxml.plt" 1 4)))<br>><br>> (define test<br>> (apply
<br>> string-append<br>> (sxml:clean-feed<br>> (stx:transform-dynamic<br>> (sxml:add-parents<br>> (sxml:document "<a href="http://modis.ispras.ru/Lizorkin/XML/poem.xml" target="_blank">
http://modis.ispras.ru/Lizorkin/XML/poem.xml</a>"))<br>> (stx:make-stx-stylesheet<br>> (sxml:document<br>> "<a href="http://modis.ispras.ru/Lizorkin/XML/poem2html.xsl" target="_blank">
http://modis.ispras.ru/Lizorkin/XML/poem2html.xsl</a>"<br>> '((xsl . " <a href="http://www.w3.org/1999/XSL/Transform" target="_blank">http://www.w3.org/1999/XSL/Transform</a>")))))))<br>> )
<br>><br>> (test)<br>><br>> But when I create a module with this code and then call (test) from<br>> another file I get the following error:<br>> .plt-scheme/planet/300/371/cache/lizorkin/sxml.plt/1/4/stx-
<br>> engine.ss::12970: reference to undefined identifier: sxpath<br><br></div>Something's not right, here.<br><br>1) The code you've supplied will not evaluate in the MzScheme<br>language, because 'test' is bound to a string, and not to a procedure.
<br>2) When I remove the parens around 'test', this code works fine and<br>displays the expected string.<br>3) When I wrap it in a module and evaluate it, 'test' is again bound<br>to the correct value.<br>
4) When I require this module from another one and fetch the value of<br>'test', I again get the right value.<br><br>Here's the module that I generated:<br><br>(module foo mzscheme<br><div class="Ih2E3d"> (require (planet "
sxml.ss" ("lizorkin" "sxml.plt" 1 4)))<br><br>(define test<br> (apply<br> string-append<br> (sxml:clean-feed<br> (stx:transform-dynamic<br> (sxml:add-parents<br> (sxml:document "
<a href="http://modis.ispras.ru/Lizorkin/XML/poem.xml" target="_blank">http://modis.ispras.ru/Lizorkin/XML/poem.xml</a>"))<br> (stx:make-stx-stylesheet<br> (sxml:document<br> "<a href="http://modis.ispras.ru/Lizorkin/XML/poem2html.xsl" target="_blank">
http://modis.ispras.ru/Lizorkin/XML/poem2html.xsl</a>"<br> '((xsl . " <a href="http://www.w3.org/1999/XSL/Transform" target="_blank">http://www.w3.org/1999/XSL/Transform</a>")))))))<br> )<br><br>
</div>(provide test))<br><br><br>(module foo-user mzscheme<br> (require (file "foo.ss"))<br><br> (display test)<br> )<br><font color="#888888"><br>John Clements<br><br></font></blockquote></div><br>