]> gitweb.factorcode.org Git - factor.git/commitdiff
stack-checker.*: infer doesn't need to be generic
authorBjörn Lindqvist <bjourne@gmail.com>
Sat, 6 Aug 2016 17:04:41 +0000 (19:04 +0200)
committerBjörn Lindqvist <bjourne@gmail.com>
Sat, 6 Aug 2016 17:04:41 +0000 (19:04 +0200)
basis/stack-checker/backend/backend.factor
basis/stack-checker/stack-checker.factor

index e65c1f5aa32f9da85dd1b1ef0fc0756d43abb539..19c2ac73af24df406cb869b2f30a5af0eb0f6fca 100644 (file)
@@ -157,9 +157,6 @@ M: object apply-object push-literal ;
         stack-visitor get
     ] with-scope ; inline
 
-: (infer) ( quot -- effect )
-    [ infer-quot-here ] with-infer drop ;
-
 : ?quotation-effect ( in -- effect/f )
     dup pair? [ second dup effect? [ drop f ] unless ] [ drop f ] if ;
 
index 1bf75e7ec9dca83f6a36cac34f33b1577a244859..d3d1e4e66d5e89c382f004fa2e007678d86e0488 100644 (file)
@@ -8,10 +8,8 @@ stack-checker.errors stack-checker.inlining
 stack-checker.visitor.dummy ;
 IN: stack-checker
 
-GENERIC: infer ( quot -- effect )
-
-M: callable infer ( quot -- effect )
-    (infer) ;
+: infer ( quot -- effect )
+    [ infer-quot-here ] with-infer drop ;
 
 : infer. ( quot -- )
     ! Safe to call from inference transforms.