Changeset 38265 in project


Ignore:
Timestamp:
03/15/20 01:37:45 (2 weeks ago)
Author:
Kon Lovett
Message:

better name

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release/5/string-utils/trunk/string-interpolation-syntax.scm

    r38244 r38265  
    1919(: set-sharp-string-interpolation-syntax ((or boolean procedure) -> void))
    2020;
    21 (define (set-sharp-string-interpolation-syntax proc)
     21(define (set-sharp-string-interpolation-syntax interpolator)
    2222  (set-sharp-read-syntax! #\"
    2323    (and
    24       proc
     24      interpolator
    2525      (let (
    26         (proc (if (procedure? proc) proc identity)) )
     26        (interpolator (if (procedure? interpolator) interpolator identity)) )
    2727        (lambda (rest-port)
    2828          (call-with-input-string "\""
    2929            (lambda (head-port)
    30               (let* (
    31                 ;forms [(") (body...")] so read as "...body..."
    32                 (port (make-concatenated-port head-port rest-port))
    33                 (str (read port)) )
    34                 (proc str) ) ) ) ) ) ) ) )
     30              ;forms [(") (body...")] so read as "...body..."
     31              (interpolator (read (make-concatenated-port head-port rest-port))) ) ) ) ) ) ) )
    3532
    3633) ;string-interpolation-syntax
Note: See TracChangeset for help on using the changeset viewer.