Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] GC and file descriptors
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2003-11-19 (16:44)
From: Brian Hurt <bhurt@s...>
Subject: Re: [Caml-list] GC and file descriptors
On 20 Nov 2003, skaller wrote:

> So either you give up explicit interfaces (mli files,
> signatures, etc) or you have to have an extension
> to the type system terms which allows you to state the
> exception spec.

I'd consider this a bonus :-).  There are two obvious ways you could do 

1) introduce a new keyword 'public'.  Only types and values declared 
public are exported, everything else is considered internal to the file.  
So you could have:

type public foo = This | That ;; (* exported *)
type bar = Which | What ;; (* not exported *)
let quux = ... ;; (* not exported *)
let public baz = ... ;; (* exported *)

2) introduce a new keyword 'private'.  Everything except those types and 
values marked private is exported.

Note that we're breaking working code here.

"Usenet is like a herd of performing elephants with diarrhea -- massive,
difficult to redirect, awe-inspiring, entertaining, and a source of
mind-boggling amounts of excrement when you least expect it."
                                - Gene Spafford 

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: