caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Arturo Borquez <aborquez@altavista.com>
To: wduminy@freemail.absa.co.za
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Infix
Date: 8 Sep 2001 07:35:19 -0700	[thread overview]
Message-ID: <20010908143519.5513.cpmta@c012.sfo.cp.net> (raw)

On Sat, 08 September 2001, "wduminy" wrote:

> 
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <HTML><HEAD>
> <META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
> <META content="MSHTML 5.00.2919.6307" name=GENERATOR>
> <STYLE></STYLE>
> </HEAD>
> <BODY bgColor=#ffffff>
> <DIV><FONT face=Arial size=2>Hello there,</FONT></DIV>
> <DIV><FONT face=Arial size=2>How do you define an infix operator in 
> OCAML?</FONT></DIV>
> <DIV>&nbsp;</DIV></BODY></HTML>

See documentation chapter 6.3 titled Naming objects
example: complex addition

# let ( +! ) a b = fst a +. fst b, snd a +. snd b;;
val ( +! ) : float * float -> float * float -> float * float = <fun>
# (3.0, 3.0) +! (1.0, 2.0);;
- : float * float = 4, 5

Regards.


Find the best deals on the web at AltaVista Shopping!
http://www.shopping.altavista.com
-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr


             reply	other threads:[~2001-09-08 14:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-09-08 14:35 Arturo Borquez [this message]
  -- strict thread matches above, loose matches on Subject: below --
2001-09-08  8:51 wduminy

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=20010908143519.5513.cpmta@c012.sfo.cp.net \
    --to=aborquez@altavista.com \
    --cc=caml-list@inria.fr \
    --cc=wduminy@freemail.absa.co.za \
    /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;
as well as URLs for NNTP newsgroup(s).