
Hi, Reading this: http://netsuperbrain.com/blog/posts/introducing-reactive-events/ I stumble upon this: type BellMachine = Event () -> Event () Google did not tell me, what this means. I understand type BellMachine = Event() but the rest is completely strange to me. What does it mean or where can I find out? Thanks! Nathan

A "type" can be both a synonym for both another type or a function. For example:
type ProcessIntList = [Int] -> [Int]
add_one :: ProcessIntList
add_one = map ((+) 1)
is the same as:
add_one :: [Int] -> [Int]
add_one = map ((+) 1)
-deech
On 6/8/10, Nathan Huesken
Hi,
Reading this: http://netsuperbrain.com/blog/posts/introducing-reactive-events/
I stumble upon this:
type BellMachine = Event () -> Event ()
Google did not tell me, what this means. I understand
type BellMachine = Event()
but the rest is completely strange to me.
What does it mean or where can I find out?
Thanks! Nathan _______________________________________________ Beginners mailing list Beginners@haskell.org http://www.haskell.org/mailman/listinfo/beginners

Hi This is a typo - caused in the translation to HTML: type BellMachine = Event () -> Event () A Bell Machine is a function from Event to Event. Representing state machines as functions from their input to their output is quite a common pattern in Haskell. Best wishes Stephen

Well, that makes complete sense.
Just out of curiosity, is it my browser or a problem with the site?
Regards,
Nathan
On Tue, 8 Jun 2010 18:52:20 +0100
Stephen Tetley
Hi
This is a typo - caused in the translation to HTML:
type BellMachine = Event () -> Event ()
A Bell Machine is a function from Event to Event.
Representing state machines as functions from their input to their output is quite a common pattern in Haskell.
Best wishes
Stephen

On Tuesday 08 June 2010 19:58:32, Nathan Huesken wrote:
Well, that makes complete sense. Just out of curiosity, is it my browser or a problem with the site?
Not your browser: type</span> BellMachine <span style="color: #339933; font-weight: bold;">=</span> Event <span style="color: green;">(</span><span style="color: green;">)</span> <span style="color: #339933; font- weight: bold;">-</span>> Event <span style="color: green;">(</span><span style="color: green;">) See the > ?
Regards, Nathan
On Tue, 8 Jun 2010 18:52:20 +0100
Stephen Tetley
wrote: Hi
This is a typo - caused in the translation to HTML:
type BellMachine = Event () -> Event ()
A Bell Machine is a function from Event to Event.
Representing state machines as functions from their input to their output is quite a common pattern in Haskell.
Best wishes
Stephen
_______________________________________________ Beginners mailing list Beginners@haskell.org http://www.haskell.org/mailman/listinfo/beginners

On Tuesday 08 June 2010 17:14:19, Nathan Huesken wrote:
Hi,
Reading this: http://netsuperbrain.com/blog/posts/introducing-reactive-events/
I stumble upon this:
type BellMachine = Event () -> Event ()
Html escaping hiccup (several more of that on the page). It should be type BellMachine = Event () -> Event () so BellMachine is an alias for the type of functions mapping an Event () to an Event ().
Google did not tell me, what this means. I understand
type BellMachine = Event()
but the rest is completely strange to me.
What does it mean or where can I find out?
Thanks! Nathan

I've been doing way too much HTML - I automatically translated ~>
in my head. Ugh.
-deech
On 6/8/10, Daniel Fischer
On Tuesday 08 June 2010 17:14:19, Nathan Huesken wrote:
Hi,
Reading this: http://netsuperbrain.com/blog/posts/introducing-reactive-events/
I stumble upon this:
type BellMachine = Event () -> Event ()
Html escaping hiccup (several more of that on the page).
It should be
type BellMachine = Event () -> Event ()
so BellMachine is an alias for the type of functions mapping an Event () to an Event ().
Google did not tell me, what this means. I understand
type BellMachine = Event()
but the rest is completely strange to me.
What does it mean or where can I find out?
Thanks! Nathan
_______________________________________________ Beginners mailing list Beginners@haskell.org http://www.haskell.org/mailman/listinfo/beginners
participants (4)
-
aditya siram
-
Daniel Fischer
-
Nathan Huesken
-
Stephen Tetley