]> gitweb.factorcode.org Git - factor.git/commitdiff
words: add unintern-word definition
authorCapital <CapitalEx@protonmail.com>
Fri, 25 Aug 2023 02:39:34 +0000 (22:39 -0400)
committerJohn Benediktsson <mrjbq7@gmail.com>
Fri, 25 Aug 2023 03:55:29 +0000 (20:55 -0700)
core/words/words.factor

index f697c3c320c44c10e027c5026c1e97cd5a837dee..749824e6ed2fc73d10df2fbac1c78eabcda2e37d 100644 (file)
@@ -199,6 +199,8 @@ M: word reset-word
 : <word> ( name vocab -- word )
     over hashcode over hashcode hash-combine >fixnum (word) dup new-word ;
 
+PREDICATE: uninterned-word < word vocabulary>> not ;
+
 : <uninterned-word> ( name -- word )
     f \ <uninterned-word> counter >fixnum (word)
     new-words get [ dup new-word ] when ;