Welcome to the CHICKEN Scheme pasting service

read/write json blocking with medea added by caolanm on Mon Apr 10 12:24:57 2017

;; medea
(use medea)

(receive (in-a out-a in-b out-b) (unix-pair)
  (write-json '((hello . "world")) out-a)
  (print (read-json in-b)))

;; the above hangs...


;; but these work:

;; s-expressions
(receive (in-a out-a in-b out-b) (unix-pair)
  (write '((hello . "world")) out-a)
  (print (read in-b)))

;; => ((hello . "world"))

;; bencode
(use bencode)

(receive (in-a out-a in-b out-b) (unix-pair)
  (write-bencode '((hello . "world")) out-a)
  (print (read-bencode in-b)))

;; => ((hello . "world"))

Your annotation:

Enter a new annotation:

Your nick:
The title of your paste:
Your paste (mandatory) :
What's the procedure to access a character in a string by index in R5RS?
Visually impaired? Let me spell it for you (wav file) download WAV