From: Philippe Veber <philippe.veber@gmail.com>
To: Lukasz Stafiniak <lukstafi@gmail.com>
Cc: caml users <caml-list@inria.fr>
Subject: Re: [Caml-list] Signals of signals in react
Date: Fri, 8 Mar 2013 14:55:47 +0100 [thread overview]
Message-ID: <CAOOOohTJ3BD+oX-qqpYAzHj+JgK9V9KgmxKANUpzV=3vwzadrw@mail.gmail.com> (raw)
In-Reply-To: <CAJMfKEXhJ1S8TY8FvUhBe=KAJ-m+k+72R+49V1LFMHBcbppJRQ@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 992 bytes --]
2013/3/8 Lukasz Stafiniak <lukstafi@gmail.com>
>
>
>
> On Fri, Mar 8, 2013 at 10:43 AM, Philippe Veber <philippe.veber@gmail.com>wrote:
>
>> Dear functional-reactive camlers,
>>
>> In order to change the dependencies between signals dynamically, one can
>> use the switch function whose type is:
>>
>> utop $ React.S.switch;;
>> - : ?eq:('a -> 'a -> bool) -> 'a React.signal -> 'a React.signal
>> React.event -> 'a React.signal = <fun>
>>
>> However I often find myself wanting to write signals of signals, and I
>> wrote the following definition to cope with them:
>>
>> val bind_s : 'a React.signal -> ('a -> 'b React.signal) -> 'b
>
>
> "Bind" is the basic building block of the Froc library:
>
> val bind :
> ?eq:('a -> 'a -> bool) ->
> 'b Froc.behavior ->
> ('b -> 'a Froc.behavior) -> 'a Froc.behavior
>
> I know I'm not answering your question...
>
You do, at least partially: now I know this style is natural at least in
one FRP library. Too bad it's not the one I use :o).
[-- Attachment #2: Type: text/html, Size: 1977 bytes --]
next prev parent reply other threads:[~2013-03-08 13:56 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-08 9:43 Philippe Veber
2013-03-08 11:51 ` Lukasz Stafiniak
2013-03-08 13:55 ` Philippe Veber [this message]
2013-03-08 14:21 ` Daniel Bünzli
2013-03-08 15:02 ` Daniel Bünzli
2013-03-08 22:21 ` Philippe Veber
2013-03-08 22:17 ` Philippe Veber
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAOOOohTJ3BD+oX-qqpYAzHj+JgK9V9KgmxKANUpzV=3vwzadrw@mail.gmail.com' \
--to=philippe.veber@gmail.com \
--cc=caml-list@inria.fr \
--cc=lukstafi@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox