summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--module/language/glil/compile-assembly.scm4
1 files changed, 3 insertions, 1 deletions
diff --git a/module/language/glil/compile-assembly.scm b/module/language/glil/compile-assembly.scm
index d02b9030c..a0818227d 100644
--- a/module/language/glil/compile-assembly.scm
+++ b/module/language/glil/compile-assembly.scm
@@ -190,7 +190,9 @@
;;
(define (build-object-table x)
(define (add store x)
- (vhash-cons x (1+ (vlist-length store)) store))
+ (if (vhash-assoc x store)
+ store
+ (vhash-cons x (1+ (vlist-length store)) store)))
(record-case x
((<glil-program> meta body)
(fold (lambda (x table)