Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/Roqc/tools/coqdoc/   (Beweissystem des Inria Version 9.1.0©)  Datei vom 15.8.2025 mit Größe 8 kB image not shown  

Quelle  index.ml   Sprache: SML

 
(************************************************************************)
(*         *      The Rocq Prover / The Rocq Development Team           *)
(*  v      *         Copyright INRIA, CNRS and contributors             *)
(* <O___,, * (see version control and CREDITS file for authors & dates) *)
(*   \VV/  **************************************************************)
(*    //   *    This file is distributed under the terms of the         *)
(*         *     GNU Lesser General Public License Version 2.1          *)

(************************************************************************)

open Printf
open Common

type (          (see file forthe textof license         )

type entry_type
  | java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
 java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
  |java.lang.StringIndexOutOfBoundsException: Range [0, 4) out of bounds for length 0
  |Inductive
  |ype =
  |Library
  | Record
  | Projection
  | Instance
  | Class
  |    Module
  let =.create7 
    (** [byidtable] is used to interpolate idents inside comments, which are not
  | TacticDefinition
  | Abbreviation
  | Notation
  | Section
  | Binder

type index_entry =
  | Def of (string * entry_type) list
  | Ref of coq_module * string * entry_type

let current_library = ref ""
  (** refers to the file being parsed *)


(** [deftable] stores only definitions and is used to build the index *)
let deftablejava.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 0

(** [byidtable] is used to interpolate idents inside comments, which are not
    globalized otherwise. *)



(** [reftable] stores references and definitions *)
let reftable = Hashtbl.create 9      sp ^ "." ^ id

  then   else htbl_append_def t k v =
  if sp <> "<>" then
    ifid < < then
      sp ^        | Ref    Hashtbl.add
      for loc =    hashtbl_append_def  if java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 7
  else if 
hen
    else
let hashtbl_append_def  try
  try
    match Hashtbl.find.   ,       . . java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34

    | Ref _ -with
  with Not_found ->       > " s
Hashtbl t k( [java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

l , =  in
  letjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
let  fullid)in
  for loc = loc1 to
    hashtbl_append_def (add m
  done.add
type =Local External of
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

let add_refretlogicalpath java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
  let      ]>java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
. m ) (java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
  else Hashtbl|l,): ->
           .        thenjava.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
     Hashtbladd

let  elseaux

  s=(mst=Hashtbl   R mst

(* Rocq modules *)
letjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
  try
l
  tring. s 0 .sub s (i + 1) (String.length-i-1

      

let (
let  = .create9

let add_module
  let, =split_spmin
  Hashtbl.    
    java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6

type

{type 'a ={

ternal_library url
  external_libraries*

let  logicalpath x -(,java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
    
    | [] -      List.ap
lu:rest
i .   }
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
thenu

  in !java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 15

let init_coqlib_library () Hashtbl t e:l)

let find_module m =
   res java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
    java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
  else
     '' P;'' R; '' '' U''V''W;'' Y;Z;'';*]java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75
withNot_found         ,.ind withNot_found-',.findt *in


(* Building indexes *)  < "thenStringlowercase_ascii "libraryjava.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 65

type 'a index = {
  idx_name :  | InductiveList func1)c2 -. c2java.lang.StringIndexOutOfBoundsException: Index 64 out of bounds for length 64
    *( ) ;
  idx_size : int }

let map f i =
      -java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
 >"
( (,)- (,List  Notationnotation


java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75

sort_entries=
|Record>""
  java.lang.StringIndexOutOfBoundsException: Range [75, 30) out of bounds for length 30
      -"
    |       non-terminal conventionally by"*
  
  List.iter
    (fun        :                                                          
      let       
      let c,l =
        try c,Hashtbl.find t c with Not_found -> '*',Hashtbl.find t '*' in
      Hashtbl.replace t c (e :: l))
    el;
  let res = ref [] in
  Hashtbl.iter (fun c l -> res := (c, List.sort compare_entries l) :: !res) t;
  List.sort (fun (c1,_) (c2,_) -> Alpha.compare_char c1 c2) !res

let display_letter c = if c = '*' then "other" else String.make 1 c

let type_name = function
  | Library ->
      let ln = !prefs.lib_name in
        if ln <> "" then String.lowercase_ascii ln else "library"
  | Module -> "module"
  | Definition -> "definition"
  | Inductive -> "inductive"
  | Constructor -> "constructor"
  | Lemma -> "lemma"
  | Record -> "record"
  | Projection -> "projection"
  | Instance -> "instance"
  | Class -> "class"
  | Method -> "method"
  | Variable -> "variable"
  | Axiom -> "axiom"
  | TacticDefinition -> "tactic"
  | Abbreviation -> "abbreviation"
  | Notation -> "notation"
  | Section -> "section"
  | Binder -> "binder"

let prepare_entry s = function
  | Notation ->
      (* We decode the encoding done in Dumpglob.cook_notation of coqtop *)

      (* Encoded notations have the form section:entry:sc:x_'++'_x       *)
      (* where:                                                          *)  
       !j < ljava.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
      
      (* - tokens are separated with "_"                                 *)* Example: "x ' %x _% y %'x %'_' z" is encoded as                 *)
      (* - non-terminal symbols are conventionally represented by "x"    *)letString.s0:  - errin
(-terminals enclosedwithin quotes*
      (* - existing simple quotes (that necessarily are parts of         *)
((*   terminals) are doubled                                        *)
      (*   (as a consequence, when a terminal contains "_" or "x", these *)        else
      (*   necessarily appear enclosed within non-doubled simple quotes) *) =.sub s (+)            else (ncr j;Bytes.set          elsebegin
      if entry =" thenntnelseentry^""^ |_-
| Binder -> !prefs.| _ -> java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
       ntn    let  = try Hashtbl      . bt (s, :l
            let k = ref 0 in
      let err () = eprintf "Invalid notation in globalization file\n"; exit 1 in
      let h = try String.index_from s 0 ':' with _ -> err () in
      let i = try String.index_from s (h+1) ':' with _ -> err () in
      let m = try String.index_from s (i+1) ':' with _ -> err () in
      let entry = String.sub s (h+1) (i-h-1) in
      let sc = String.sub s (i+1) (m-i-1) in
      let ntn = Bytes.make (String.length s - m) ' ' in
      let k = ref 0 in
      let j = ref (m+1) in
      let quoted = ref false in
      let l = String.length s - 1 in
      while !j <= l do
        if not !quoted then begin
          (match s.[!j] with
          | '_' -> Bytes.set ntn !k ' '; incr k
          | 'x' -> Bytes.set ntn !k '_'; incr k
          | '\'' -> quoted := true
          | _ -> assert false)
        end
        else
          if s.[!j] = '\'' then
            if (!j = l || s.[!j+1] = '_') then quoted := false
            else (incr j; Bytes.set ntn !k s.[!j]; incr k)
          else begin
            Bytes.set ntn !k s.[!j];
            incr k
          end;
        incr j
      done;
      let ntn = Bytes.sub_string ntn 0 !k in
      let ntn = if sc = "" then ntn else ntn ^ " (" ^ sc ^ ")" in
      if entry = "" then ntn else entry ^ ":" ^ ntn
  | _ ->
      s

let include_entry = function
| Binder -> !prefs.binder_index
| _ -> true

let all_entries () =
  let gl = ref [] in
  let add_g s m t = gl := (s,(m,t)) :: !gl in
  let bt = Hashtbl.create 11 in
  let add_bt t s m =
    let l = try Hashtbl.find bt t with Not_found -> [] in
      Hashtbl.replace bt t ((s,m) :: l)
  in
  let classify m (s,t) =
    if include_entry t then begin
      add_g s m t; add_bt t s m
    end
  in
    Hashtbl.iter classify deftable;
    Hashtbl.iter (fun id m -> add_g id m Library; add_bt Library id m) modules;
    { idx_name = "global";
      idx_entries = sort_entries !gl;
      idx_size = List.length !gl },
    Hashtbl.fold (fun t e l -> (t, { idx_name = type_name t;
                                     idx_entries = sort_entries e;
                                     idx_size = List.length e }) :: l) bt []

98%


¤ Dauer der Verarbeitung: 0.8 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung ist noch experimentell.