Created
November 17, 2015 00:16
-
-
Save cbaggers/5f7601b48e006cee8453 to your computer and use it in GitHub Desktop.
flow ids with assignment
This file contains hidden or 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
;; So this code has an assignment (the `setq`) in a deep scope | |
(defshader test () | |
(let ((x 1)) | |
(v! x 0) | |
(progn | |
(let ((z 3)) | |
(setq x z))) | |
(v! x 0 0 0))) | |
;; here we can see the flow-ids the analyzer gave the values used in the two vector constructors | |
;; e.g. (v! x y z w) | |
(V! 506 507) | |
(V! 509 510 511 522) | |
;; and we can see that even though the first arg of both calls is x they have different flow ids | |
;; whereas without the set you get | |
(defshader test () | |
(let ((x 1)) | |
(v! x 0) | |
(progn | |
(let ((z 3)) | |
x)) | |
(v! x 0 0 0))) | |
;; and you can see you have the same flow id for the first arg in both cases | |
(V! 514 515) | |
(V! 514 518 519 520) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment