Changeset 40236 in project


Ignore:
Timestamp:
06/30/21 19:19:40 (4 weeks ago)
Author:
Mario Domenech Goulart
Message:

set-read-syntax-example: update to C5

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wiki/set-read-syntax-example

    r27938 r40236  
    33In the example below we are called when the reader encounters the opening { character, and we then (read) in S-expressions in a loop until we detect a } character.  Of course, what we (read) may well be another opening brace, which will call us recursively.
    44
    5  ;; 2007/10 zb
    6  (set-read-syntax! #\{
     5  ;; 2007/10 zb
     6  (import (chicken read-syntax))
     7  (set-read-syntax! #\{
    78    (lambda (port)
    89      (let loop ((c (peek-char port)) (exps '()))
Note: See TracChangeset for help on using the changeset viewer.