Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: skaller <skaller@users.sourceforge.net>
To: Jean-Christophe Filliatre <filliatr@lri.fr>
Cc: Erik de Castro Lopo <ocaml-erikd@mega-nerd.com>,
	caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Reporting on sucess/failure of tail recursion
Date: Sat, 03 Dec 2005 10:58:49 +1100	[thread overview]
Message-ID: <1133567929.17049.7.camel@rosella> (raw)
In-Reply-To: <17296.25990.261724.744405@gargle.gargle.HOWL>

On Fri, 2005-12-02 at 16:17 +0100, Jean-Christophe Filliatre wrote:
> Erik de Castro Lopo writes:
>  > with a no-recursive outer function and a tail recursive inner function.
>  > It would still be nice to know if the inner function is tail recursive.

> As  already explained by  Basile, the  right notion  is that  of "tail
> call"  not of "tail  recursive function" 

> Being warned of non-tail calls may be useful in some situations, but I
> guess the  issue is often the call  to a library function  that is not
> tail recursive. 
 ***************

Hehe .. committing the same error yourself.

> That's  why you need the documentation  to be explicit
> about that...

No, it is meaningless: the idea only applies to a definition.
The only visible part of a Library function is its interface.
Furthermore, it is very unlikely a call to a library function
would be recursive, whether it is in tail position or not.

What needs to be documented for a library function is its
complexity (time/space etc). In this sense the documentation
of the C++ Standard Library should be taken as an examplar.

-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


  reply	other threads:[~2005-12-02 23:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-02  9:09 Erik de Castro Lopo
2005-12-02  9:13 ` [Caml-list] " Jonathan Roewen
2005-12-02  9:25   ` Erik de Castro Lopo
2005-12-02  9:29 ` basile
2005-12-02 10:16   ` Erik de Castro Lopo
2005-12-02 15:17     ` Jean-Christophe Filliatre
2005-12-02 23:58       ` skaller [this message]
2005-12-02 10:45   ` David MENTRE
2005-12-03  0:28 David Thomas
2005-12-04  4:11 ` Andres Varon

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=1133567929.17049.7.camel@rosella \
    --to=skaller@users.sourceforge.net \
    --cc=caml-list@yquem.inria.fr \
    --cc=filliatr@lri.fr \
    --cc=ocaml-erikd@mega-nerd.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