Three type-constructor comments spell the map type the way the parser does
This commit is contained in:
parent
f47f9ffe59
commit
5a4f12bacd
@ -16,7 +16,7 @@ and texpr_kind =
|
|||||||
| Tname of string (* i32 bool Cursor string *)
|
| Tname of string (* i32 bool Cursor string *)
|
||||||
| Tslice of texpr (* [u8] ptr+len *)
|
| Tslice of texpr (* [u8] ptr+len *)
|
||||||
| Tarray of len * texpr (* [4 f32] [rows [cols u32]] *)
|
| Tarray of len * texpr (* [4 f32] [rows [cols u32]] *)
|
||||||
| Tmap of texpr * texpr (* {string i32} *)
|
| Tmap of texpr * texpr (* (Map string i32) *)
|
||||||
| Tapp of string * texpr list (* (Ptr Cursor) (Option f64) *)
|
| Tapp of string * texpr list (* (Ptr Cursor) (Option f64) *)
|
||||||
| Tfn of texpr list * texpr (* (Fn [a a] bool) *)
|
| Tfn of texpr list * texpr (* (Fn [a a] bool) *)
|
||||||
|
|
||||||
|
|||||||
@ -17,7 +17,9 @@ and value =
|
|||||||
| Byte of int (* \space \0 \( (0..255) *)
|
| Byte of int (* \space \0 \( (0..255) *)
|
||||||
| List of t list (* (f x) *)
|
| List of t list (* (f x) *)
|
||||||
| Vec of t list (* [1 2 3] and every binding/type bracket *)
|
| Vec of t list (* [1 2 3] and every binding/type bracket *)
|
||||||
| Map of t list (* {.field v} a struct value, {K V} a type. The
|
| Map of t list (* {.field v} a struct value, and a defn's
|
||||||
|
{:where ...} clause. Braces are not a type: the
|
||||||
|
{K V} spelling was withdrawn for (Map K V). The
|
||||||
colon spelling is left for map literals. *)
|
colon spelling is left for map literals. *)
|
||||||
|
|
||||||
let make v loc = { v; loc }
|
let make v loc = { v; loc }
|
||||||
|
|||||||
@ -28,7 +28,7 @@ type t =
|
|||||||
| Enum of string
|
| Enum of string
|
||||||
| Slice of t (* [T] ptr+len, non-owning *)
|
| Slice of t (* [T] ptr+len, non-owning *)
|
||||||
| Array of int64 * t (* [n T] inline, a value, copies *)
|
| Array of int64 * t (* [n T] inline, a value, copies *)
|
||||||
| Map of t * t (* {K V} *)
|
| Map of t * t (* (Map K V) *)
|
||||||
| Ptr of t (* (Ptr T) *)
|
| Ptr of t (* (Ptr T) *)
|
||||||
(* [Allocator]: a builtin opaque type, the way [string] is a builtin
|
(* [Allocator]: a builtin opaque type, the way [string] is a builtin
|
||||||
ptr+len. It is a [Types.t] case with no user-writable constructor, which
|
ptr+len. It is a [Types.t] case with no user-writable constructor, which
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user