Implement port-properties.
authorChris Hanson <org/chris-hanson/cph>
Wed, 8 Mar 2017 05:59:18 +0000 (21:59 -0800)
committerChris Hanson <org/chris-hanson/cph>
Wed, 8 Mar 2017 05:59:18 +0000 (21:59 -0800)
src/runtime/port.scm
src/runtime/runtime.pkg

index ef1f05d59e5542fe4af9318566e287f7379d665d..ebf5d06523eede887ddd90c494223e57860e9b66 100644 (file)
@@ -527,6 +527,9 @@ USA.
   (guarantee symbol? name 'remove-port-property!)
   (((port-metadata port) 'delete!) name))
 
+(define (port-properties port)
+  (alist-copy (((port-metadata port) 'get-alist))))
+
 (define (transcribe-char char port)
   (let ((tport (textual-port-transcript port)))
     (if tport
index bfc806f1492066a02d29b48fcee0cda2ee4b6ed3..af8b1b593e6289329b302d9c8b447354b22a6c8e 100644 (file)
@@ -2595,6 +2595,7 @@ USA.
          output-port-open?
          output-port-terminal-mode
          output-port?
+         port-properties
          port-property
          port/coding
          port/known-coding?