From 94c89e55e6e8cbf27898f62a18b7edcae29aed7b Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Mon, 31 Aug 2009 16:48:10 -0500 Subject: [PATCH] tools.deploy.shaker: strip out call( and execute( runtime checking in a way that still allows the inlining optimization to work --- basis/tools/deploy/shaker/strip-call.factor | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/basis/tools/deploy/shaker/strip-call.factor b/basis/tools/deploy/shaker/strip-call.factor index d0593b6c15..0ecc22e4c0 100644 --- a/basis/tools/deploy/shaker/strip-call.factor +++ b/basis/tools/deploy/shaker/strip-call.factor @@ -1,10 +1,14 @@ ! Copyright (C) 2009 Slava Pestov ! See http://factorcode.org/license.txt for BSD license. -IN: tools.deploy.shaker.call - +USING: combinators.private kernel ; IN: combinators -USE: combinators.private -: call-effect ( word effect -- ) call-effect-unsafe ; inline +: call-effect ( word effect -- ) call-effect-unsafe ; -: execute-effect ( word effect -- ) execute-effect-unsafe ; inline \ No newline at end of file +: execute-effect ( word effect -- ) execute-effect-unsafe ; + +IN: compiler.tree.propagation.call-effect + +: call-effect-unsafe? ( quot effect -- ? ) 2drop t ; inline + +: execute-effect-unsafe? ( word effect -- ? ) 2drop t ; inline \ No newline at end of file