> What is that ">>="?It is defined here: http://ocsigen.org/docu/1.2.0/Lwt.html
> Does it have a name so that I could make some search about
Basically, x >>= y is an alternative notation for Lwt.bind x y.
The Ocaml language allows you to define new prefix or infix operators,
since they are just syntactic sugar for function application. You can
also treat an operator as a function by enclosing it with parentheses
(which I'm sure you've seen by now; most tutorials cover this).
Hope that helps,
- It is syntactic sugar for 'bind' - see the documentation at
On Tue, Nov 17, 2009 at 2:04 PM, Rakotomandimby Mihamina <
>[Non-text portions of this message have been removed]
> Hi all,
> In http://ocsigen.org/eliom/manual/1.2.0/2#p2sessiondata I find this
> portion of code:
> let session_data_example_with_post_params_handler sp _ login =
> Eliom_sessions.close_session ~sp () >>= fun () ->
> Eliom_sessions.set_volatile_session_data ~table:my_table ~sp login;
> (head (title (pcdata "")) )
> [p [pcdata ("Welcome " ^ login ^ ". You are now connected.");
> br ();
> Eliom_predefmod.Xhtml.a session_data_example sp [pcdata "Try again"] ()
> What is that ">>="?
> Does it have a name so that I could make some search about it?
> Thank you.
> Architecte Informatique chez Blueline/Gulfsat:
> Administration Systeme, Recherche & Developpement
> +261 33 11 207 36