From 1ef9ff8be51612ba603ddd39040001ad18fd2203 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Thu, 16 Nov 2023 15:40:05 +0000 Subject: yaml: Comment on various cases handled by scm->yaml. * ccwl/yaml.scm (scm->yaml): Comment on cases handled. --- ccwl/yaml.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ccwl/yaml.scm b/ccwl/yaml.scm index 07ed913..00942de 100644 --- a/ccwl/yaml.scm +++ b/ccwl/yaml.scm @@ -99,24 +99,29 @@ PORT. LEVEL is an internal recursion variable." (display-atom single-element port) (display "]" port) (newline port)) + ;; General arrays (#(head tail ...) (display-array-element head port level) (for-each (lambda (element) (indent-level port level) (display-array-element element port level)) tail)) + ;; Empty arrays (#() (display "[]" port) (newline port)) + ;; General dictionaries ((head tail ...) (display-dictionary-entry head port level) (for-each (lambda (entry) (indent-level port level) (display-dictionary-entry entry port level)) tail)) + ;; Empty dictionaries (() (display "{}" port) (newline port)) + ;; Atoms (symbol (display-atom symbol port) (newline port)))) -- cgit v1.2.3