[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-users] extension of __declare(substitute, "..; ...") syntax?

From: Daniel B. Faken
Subject: [Chicken-users] extension of __declare(substitute, "..; ...") syntax?
Date: Thu, 29 Jan 2004 13:47:00 -0500 (EST)


  I'm looking to convert some imported C functions' names to lower-case.  
For example, glLoadMatrix -> gl-load-matrix.
  I haven't been able to find a way to do this with the 'substitute' 
syntax, because (AFAIK) it only allows back-references, so I can't switch 
the case short of doing something like
__declare(substitute, "([a-z])A;\1a")
__declare(substitute, "([a-z])B;\1b")
__declare(substitute, "([a-z])C;\1c")

  I tracked this back to the implementation of string-substitute (in 
pcre.scm), and I didn't see any simple way to do this.

  Thoughts?  Should I implement a more general method?

Daniel Faken

reply via email to

[Prev in Thread] Current Thread [Next in Thread]