<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi all,<div><br class="webkit-block-placeholder"></div><div>I'm converting some code from PLT 37x to the scheme/base language in PLT v399, and I'm getting a rather odd error. When I combine keywords and the "cut" macro I get an error message. For example:</div><div><br class="webkit-block-placeholder"></div><div><font class="Apple-style-span" face="Monaco"> 1 #lang scheme/base</font></div><div><font class="Apple-style-span" face="Monaco"> 2</font></div><div><font class="Apple-style-span" face="Monaco"> 3 (require srfi/26/cut)</font></div><div><font class="Apple-style-span" face="Monaco"> 4</font></div><div><font class="Apple-style-span" face="Monaco"> 5 (define (add #:a a #:b b)</font></div><div><font class="Apple-style-span" face="Monaco"> 6 (+ a b))</font></div><div><font class="Apple-style-span" face="Monaco"> 7</font></div><div><font class="Apple-style-span" face="Monaco"> 8 (define add2</font></div><div><font class="Apple-style-span" face="Monaco"> 9 (cut add #:a <> #:b 2))</font></div><div><font class="Apple-style-span" face="Monaco"> 10</font></div><div><font class="Apple-style-span" face="Monaco"> 11 (display (add2 1))</font></div><div><font class="Apple-style-span" face="Monaco"><br class="webkit-block-placeholder"></font></div><div><font class="Apple-style-span" face="Monaco"><span class="Apple-style-span" style="font-family: 'Lucida Grande'; "><div>I get the following error message (in this example at line 9):</div><div><br class="webkit-block-placeholder"></div><div><font class="Apple-style-span" face="Monaco"> #%datum: keyword used as an expression in: #:a </font></div><div><font class="Apple-style-span" face="Monaco"><br class="webkit-block-placeholder"></font></div><div><font class="Apple-style-span" face="Monaco"><span class="Apple-style-span" style="font-family: 'Lucida Grande'; "><div>It doesn't seem like this should cause a problem because AFAIK "cut" rewrites to a simple lambda. However, it did occur to me that the lambda in the mzscheme language (in which "cut.ss" is presumably written) is different to the lambda from scheme/base. Is this the source of the problem or am I barking up the wrong tree? </div><div><br class="webkit-block-placeholder"></div><div>It'd be really nice to convince cut to work with keyword lambdas - I use it *everywhere*.</div><div><br class="webkit-block-placeholder"></div><div>Cheers,</div><div><br class="webkit-block-placeholder"></div><div>-- Dave</div><div><br class="webkit-block-placeholder"></div></span></font></div></span></font></div></body></html>