forked from ocaml/merlin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
84 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
(**************************************************************************) | ||
(* *) | ||
(* OCaml *) | ||
(* *) | ||
(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *) | ||
(* *) | ||
(* Copyright 1996 Institut National de Recherche en Informatique et *) | ||
(* en Automatique. *) | ||
(* *) | ||
(* All rights reserved. This file is distributed under the terms of *) | ||
(* the GNU Lesser General Public License version 2.1, with the *) | ||
(* special exception on linking described in the file LICENSE. *) | ||
(* *) | ||
(**************************************************************************) | ||
|
||
(** Auxiliary AST types used by parsetree and typedtree. | ||
{b Warning:} this module is unstable and part of | ||
{{!Compiler_libs}compiler-libs}. | ||
*) | ||
|
||
type constant = | ||
Const_int of int | ||
| Const_char of char | ||
| Const_string of string * Location.t * string option | ||
| Const_float of string | ||
| Const_int32 of int32 | ||
| Const_int64 of int64 | ||
| Const_nativeint of nativeint | ||
|
||
type rec_flag = Nonrecursive | Recursive | ||
|
||
type direction_flag = Upto | Downto | ||
|
||
(* Order matters, used in polymorphic comparison *) | ||
type private_flag = Private | Public | ||
|
||
type mutable_flag = Immutable | Mutable | ||
|
||
type virtual_flag = Virtual | Concrete | ||
|
||
type override_flag = Override | Fresh | ||
|
||
type closed_flag = Closed | Open | ||
|
||
type label = string | ||
|
||
type arg_label = | ||
Nolabel | ||
| Labelled of string (** [label:T -> ...] *) | ||
| Optional of string (** [?label:T -> ...] *) | ||
|
||
type 'a loc = 'a Location.loc = { | ||
txt : 'a; | ||
loc : Location.t; | ||
} | ||
|
||
|
||
type variance = | ||
| Covariant | ||
| Contravariant | ||
| NoVariance | ||
|
||
type injectivity = | ||
| Injective | ||
| NoInjectivity | ||
|
||
let string_of_label = function | ||
Nolabel -> "" | ||
| Labelled s -> s | ||
| Optional s -> "?"^s |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -65,3 +65,5 @@ type variance = | |
type injectivity = | ||
| Injective | ||
| NoInjectivity | ||
|
||
val string_of_label: arg_label -> string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters