Hi Matt - this is where getting into Gambit's sourcecode comes into the picture:<div><br></div><div>Look up load/compile-file there and trace your way down the sourcecode to the read/read-all call, this will show you which port is used. And, check if there's any callback or inheritance you can use for altering the readtable, or implement a callback yourself and recompile.</div>
<div><br></div><div>Mikael<br><div><div><br><div class="gmail_quote">2011/8/28 Matt Lamari <span dir="ltr"><<a href="mailto:matt.lamari@gmail.com">matt.lamari@gmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div bgcolor="#FFFFFF" text="#000000">
<br>
I'm using the compiler by running the gsc executable.<br>
<br>
Where do I inject the code, and for what port?<br>
<br>
I tried using (current-input-port), and executing the readtable-set!
from an expanding macro using (current-input-port), that's all I can
think of; but it doesn't apply #. .<br><br>Does somebody have this working? What is the port for the compiler's input stream when running gsc? And how/where/when should I execute this code to modify the readtable before the .scm file(s)
are run?<br>
<br>
Thanks,<br><font color="#888888">
Matt</font><div><div></div><div class="h5"><br>
<br>
<br>
<br>
<br>
On 8/27/2011 7:42 AM, Mikael wrote:
<blockquote type="cite">Hi Matt,
<div><br>
</div>
<div>For sure you can do this, just track down the port that is
(read) from on load and compile-file and perform the setting on
it. Maybe you could even make a parameterized global variable
config-sourcecode-port procedure so you can configure this as
you go - and btw maybe that's already in there.
<div>
<br>
</div>
<div>Did you say you want #. switched on for all or parts of
your scm file? The earlier ought be more straightforward to
implement.</div>
<div><br>
</div>
<div>Let the ML know what you got to.</div>
<div><br>
</div>
<div>
Brgds,</div>
<div>Mikael<br>
<br>
<div class="gmail_quote">2011/8/27 Matt Lamari <span dir="ltr"><<a href="mailto:matt.lamari@gmail.com" target="_blank">matt.lamari@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I want to know if #. or something equivalent is available
when<br>
compiling .scm files. That is, the ability to tell the
reader to<br>
directly eval a form at read time.<br>
<br>
I've been shown this:<br>
<br>
<a href="http://dynamo.iro.umontreal.ca/%7Egambit/wiki/index.php?title=Documentation:Procedure_readtable-eval-allowed?-set" target="_blank">http://dynamo.iro.umontreal.ca/~gambit/wiki/index.php?title=Documentation:Procedure_readtable-eval-allowed?-set</a><br>
<br>
But am not sure how this should be applied to reading
compiled code, if<br>
it's applicable, if it's possible.<br>
<br>
If this code or something like it should be used to
influence the<br>
reader, where should it go?<br>
<br>
What's the best way to get the ability to have #. in the
middle of<br>
compiled .scm?<br>
<br>
<br>
Thanks,<br>
Matt<br>
<br>
<br>
_______________________________________________<br>
Gambit-list mailing list<br>
<a href="mailto:Gambit-list@iro.umontreal.ca" target="_blank">Gambit-list@iro.umontreal.ca</a><br>
<a href="https://webmail.iro.umontreal.ca/mailman/listinfo/gambit-list" target="_blank">https://webmail.iro.umontreal.ca/mailman/listinfo/gambit-list</a><br>
</blockquote>
</div>
<br>
</div>
</div>
<br>
<fieldset></fieldset>
<br>
<pre>_______________________________________________
Gambit-list mailing list
<a href="mailto:Gambit-list@iro.umontreal.ca" target="_blank">Gambit-list@iro.umontreal.ca</a>
<a href="https://webmail.iro.umontreal.ca/mailman/listinfo/gambit-list" target="_blank">https://webmail.iro.umontreal.ca/mailman/listinfo/gambit-list</a>
</pre>
</blockquote>
<br>
</div></div></div>
</blockquote></div><br></div></div></div>