Version française
Home     About     Download     Resources     Contact us    
Browse thread
Extending .annot files
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Maxence Guesdon <maxence.guesdon@i...>
Subject: Re: [Caml-list] Extending .annot files
On Fri, 19 Sep 2008 11:20:36 -0700
"Nathaniel Gray" <n8gray@gmail.com> wrote:

> On Thu, Sep 18, 2008 at 10:02 AM, Xavier Leroy <Xavier.Leroy@inria.fr> wrote:
> >
> > From what I've heard, there's also an OCaml summer of code project
> > that enriched the info found in .annot files.  So, it's certainly time
> > to discuss extensions to .annot files, but let's do that globally, not
> > one at a time.  It is probably too late for inclusion in 3.11, but as
> > long as these extensions are backward compatible, inclusion in bugfix
> > releases can be considered.
> 
> I'm really happy to hear that you're open to including some of this
> stuff.  I think there are actually only a few data that one wants to
> have in .annot files (and that the compiler can reasonably provide).
> 
> For any identifier it would be good to know:
> 1. Its inferred type
> 2. Its fully-qualified module "path"

All identifiers have not a fully qualified path (think of y in
  let x = let y = ... in ...) and two identifiers may have the same
fully-qualified path. (e.g.: let x = 1;; let x = 2;;)

> 3. Where it was defined, if it was defined in the current file.

Would it be possible to have the location of the definition of all
identifiers, including the ones defined in another module (if there is
a .annot file for this module, of course) ?

> In addition, for each module referenced in the file it would be good
> to know what file the module was read from.  (This will allow some
> hope of tracking down definitions in other files)
> 
> It's hard for me to think of anything else that belongs in .annot
> files.  If I stretch a bit I suppose annotating variable definitions
> with their range of scope might be cute.  Maybe other people can think
> of more original ideas.

A module containing the functions to read .annot files, so that
all developers using these files do not develop their own module.

Regards,


-- 
Maxence Guesdon                           http://yquem.inria.fr/~guesdon/
Service Expérimentation et Développements https://devel.inria.fr/rocq/
INRIA Paris-Rocquencourt                  http://www.inria.fr/rocquencourt/