Last active
December 17, 2015 11:08
-
-
Save shanecelis/5599411 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Possible bug, or at least unexpected behavior, for typed array | |
;; literals. Demonstration below. The same storage is used | |
;; for the same literal. | |
;; | |
;; Run on guile (GNU Guile) 2.0.5 on Mac OS X. | |
;; | |
;; Shane Celis | |
(define x #f64(0. 1. 2.)) | |
(define y #f64(0. 1. 2.)) | |
;; Set the first element of x to 1. | |
(array-set! x 1 0) | |
(display x) ;; will display #f64(1.0 1.0 2.0) | |
(newline) | |
(display y) ;; will display #f64(1.0 1.0 2.0) | |
(newline) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment