annotate src/mod_db.sig @ 1985:5195378deeca

Merge in upstream
author Patrick Hurst <phurst@mit.edu>
date Sat, 15 Feb 2014 01:04:31 -0500
parents 78d7cc9c9b18
children
rev   line source
adam@1732 1 (* Copyright (c) 2012, Adam Chlipala
adam@1732 2 * All rights reserved.
adam@1732 3 *
adam@1732 4 * Redistribution and use in source and binary forms, with or without
adam@1732 5 * modification, are permitted provided that the following conditions are met:
adam@1732 6 *
adam@1732 7 * - Redistributions of source code must retain the above copyright notice,
adam@1732 8 * this list of conditions and the following disclaimer.
adam@1732 9 * - Redistributions in binary form must reproduce the above copyright notice,
adam@1732 10 * this list of conditions and the following disclaimer in the documentation
adam@1732 11 * and/or other materials provided with the distribution.
adam@1732 12 * - The names of contributors may not be used to endorse or promote products
adam@1732 13 * derived from this software without specific prior written permission.
adam@1732 14 *
adam@1732 15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
adam@1732 16 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
adam@1732 17 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
adam@1732 18 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
adam@1732 19 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
adam@1732 20 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
adam@1732 21 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
adam@1732 22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
adam@1732 23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
adam@1732 24 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
adam@1732 25 * POSSIBILITY OF SUCH DAMAGE.
adam@1732 26 *)
adam@1732 27
adam@1732 28 (* Cache of module code, with dependency information *)
adam@1732 29
adam@1732 30 signature MOD_DB = sig
adam@1732 31 val reset : unit -> unit
adam@1732 32
adam@1732 33 val insert : Elab.decl * Time.time -> unit
adam@1732 34 (* Here's a declaration, including the modification timestamp of the file it came from.
adam@1732 35 * We might invalidate other declarations that depend on this one, if the timestamp has changed. *)
adam@1732 36
adam@1732 37 val lookup : Source.decl -> Elab.decl option
adam@1737 38
adam@1737 39 (* Allow undoing to snapshots after failed compilations. *)
adam@1737 40 val snapshot : unit -> unit
adam@1737 41 val revert : unit -> unit
adam@1732 42 end