tag:blogger.com,1999:blog-5894839.post5430674117618069661..comments2023-10-03T18:59:20.162+02:00Comments on Kazimir Majorinc's Blog (currently not in use): Composing Fexprs Preserves Short-circuit Evaluation.Kazimir Majorinchttp://www.blogger.com/profile/03407339997157446200noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-5894839.post-5278435781385976732010-02-28T02:29:02.514+01:002010-02-28T02:29:02.514+01:00Hey, its pretty elegant solution.Hey, its pretty elegant solution.Kazimir Majorinchttps://www.blogger.com/profile/03407339997157446200noreply@blogger.comtag:blogger.com,1999:blog-5894839.post-22056403042913818832010-02-27T12:24:14.853+01:002010-02-27T12:24:14.853+01:00Blogger Wolverrum said...
As I understanding...Blogger Wolverrum said...<br /><br /> As I understanding increasOrder properly it has type:<br /> increaseOrder :: (b->c) -> ((a->b) -> (a->c))<br /><br /> At least above I was able to create using C#2 :)<br /><br />FuncX<FuncX<A, B>, FuncX<A, C>> Up< B, C>(FuncX<B, C> fn)<br />{return delegate(FuncX<A, B> h) {<br />return Compose(h, fn); }; }Wolverrumhttps://www.blogger.com/profile/16243788130871504076noreply@blogger.comtag:blogger.com,1999:blog-5894839.post-75822527429661158202010-02-24T03:27:57.274+01:002010-02-24T03:27:57.274+01:00Actually, it is not that bad weather if one sits i...Actually, it is not that bad weather if one sits in the bar, drink tea and rum, and watch the world through windows. I have another similar function, it is <a href="http://kazimirmajorinc.blogspot.com/2008/06/promote-your-functions.html" rel="nofollow">"increase-order"</a>. On that way I can increase order of functions, so these can apply on other functions. For example, I can define +f<br /><br />(setf +f (increase-order +))<br /><br />and +f will add functions, not numbers. <br /><br />((+f sin cos) x) ==> (+ (sin x) (cos x)) <br /><br />It was one of my first posts, so maybe it doesn't work any more - Newlisp changed, but version <a href="http://www.instprog.com/Instprog.default-library.html" rel="nofollow"> in my library </a> works.Kazimir Majorinchttps://www.blogger.com/profile/03407339997157446200noreply@blogger.comtag:blogger.com,1999:blog-5894839.post-84017878471412563102010-02-24T01:54:26.203+01:002010-02-24T01:54:26.203+01:00Really bad weather :(
>Beautiful
compose() is ...Really bad weather :(<br /><br />>Beautiful<br />compose() is a good enough approach to make code shorter, I like it :)Wolverrumhttps://www.blogger.com/profile/16243788130871504076noreply@blogger.com