Scoping rules

From: Adam P. Jenkins (ajenkins@cs.umass.edu)
Date: Sat Jun 28 1997 - 04:53:43 MET DST


Date: Fri, 27 Jun 1997 22:53:43 -0400
Message-Id: <199706280253.WAA02094@dwarin.oit.umass.edu>
From: "Adam P. Jenkins" <ajenkins@cs.umass.edu>
To: caml-list@inria.fr
Subject: Scoping rules

Hi,
        Am I right that in Caml/O'Caml, exceptions and open statements
always occur at top-level (by top-level I mean not in a let .. in
block)? What I mean is: in SML one can say

let open List
    exception LocalExc of string in
  (* in here List is open and I can use LocalExc *)

There doesn't seem to be any equivalent in Caml. Just checking if I'm
missing something. I realize that the scope of "open" and exception
can be limited to a structure, but I was looking for an even smaller
scope. Thanks.

Adam

-- 
Adam P. Jenkins 
mailto:ajenkins@cs.umass.edu



This archive was generated by hypermail 2b29 : Sun Jan 02 2000 - 11:58:11 MET