Fix restart behavior with circular vocabs, and add a test for this
parent
9ab4d53213
commit
ccab34e7c4
|
@ -171,3 +171,11 @@ forget-junk
|
||||||
] with-compilation-unit
|
] with-compilation-unit
|
||||||
|
|
||||||
[ ] [ "vocabs.loader.test.h" require ] unit-test
|
[ ] [ "vocabs.loader.test.h" require ] unit-test
|
||||||
|
|
||||||
|
|
||||||
|
[
|
||||||
|
"vocabs.loader.test.j" forget-vocab
|
||||||
|
"vocabs.loader.test.k" forget-vocab
|
||||||
|
] with-compilation-unit
|
||||||
|
|
||||||
|
[ ] [ [ "vocabs.loader.test.j" require ] [ drop :1 ] recover ] unit-test
|
||||||
|
|
|
@ -65,6 +65,7 @@ ERROR: circular-dependency name ;
|
||||||
[
|
[
|
||||||
+parsing+ >>source-loaded?
|
+parsing+ >>source-loaded?
|
||||||
dup vocab-source-path [ parse-file ] [ [ ] ] if*
|
dup vocab-source-path [ parse-file ] [ [ ] ] if*
|
||||||
|
[ +parsing+ >>source-loaded? ] dip
|
||||||
[ % ] [ assert-depth ] if-bootstrapping
|
[ % ] [ assert-depth ] if-bootstrapping
|
||||||
+done+ >>source-loaded? drop
|
+done+ >>source-loaded? drop
|
||||||
] [ ] [ f >>source-loaded? ] cleanup ;
|
] [ ] [ f >>source-loaded? ] cleanup ;
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
IN: vocabs.loader.test.j
|
||||||
|
"vocabs.loader.test.k" require
|
|
@ -0,0 +1 @@
|
||||||
|
unportable
|
|
@ -0,0 +1,2 @@
|
||||||
|
IN: vocabs.loader.test.k
|
||||||
|
USE: vocabs.loader.test.j
|
|
@ -0,0 +1 @@
|
||||||
|
unportable
|
Loading…
Reference in New Issue