Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frama-c
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Charles Southerland
frama-c
Commits
171b8020
Commit
171b8020
authored
5 years ago
by
Michele Alberti
Browse files
Options
Downloads
Patches
Plain Diff
[server] Fix some typos in Data.mli.
parent
5f18c81f
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/plugins/server/data.mli
+15
-21
15 additions, 21 deletions
src/plugins/server/data.mli
with
15 additions
and
21 deletions
src/plugins/server/data.mli
+
15
−
21
View file @
171b8020
...
...
@@ -164,24 +164,20 @@ module Tag : S_collection with type t = Syntax.tag
(** Enum factory.
You shall start by declaring a dictionnary with
[Enum.dictionary] for your values.
Then, populate the dictionary with [Enum.tag] values.
Finally, you shall call [Enum.publish] to obtain a new data module
for your type.
You shall start by declaring a dictionary with [Enum.dictionary] for your
values. Then, populate the dictionary with [Enum.tag] values. Finally, you
shall call [Enum.publish] to obtain a new data module for your type.
You have two options for computing tags: either you provide values
when
declaring tags, and these tags will be associated to registered
values for
both directions;
alternatively you might provide a [~tag] function to
[Enum.publish].
You have two options for computing tags: either you provide values
when
declaring tags, and these tags will be associated to registered
values for
both directions;
alternatively you might provide a [~tag] function to
[Enum.publish].
The difficulty when providing values only at tag definition is to ensure
that all possible value has been registered.
The conversion values from and to json may fail when no value has been
registered with tags.
*)
registered with tags. *)
module
Enum
:
sig
...
...
@@ -191,12 +187,12 @@ sig
val
tag_name
:
'
a
tag
->
string
(** Creates an opened, empty diction
n
ary. *)
(** Creates an opened, empty dictionary. *)
val
dictionary
:
page
:
Doc
.
page
->
name
:
string
->
title
:
string
->
descr
:
Markdown
.
text
->
unit
->
'
a
dictionary
(** Register a new tag in the diction
n
ary.
(** Register a new tag in the dictionary.
The default label is the capitalized name.
The provided value, if any, will be used for decoding json tags.
If would be used also for encoding values to json tags if no [~tag]
...
...
@@ -234,19 +230,17 @@ sig
?
value
:
'
a
->
unit
->
'
a
tag
(** Obtain all the tags registered in the diction
n
ary so far. *)
(** Obtain all the tags registered in the dictionary so far. *)
val
tags
:
'
a
dictionary
->
Tag
.
t
list
val
page
:
'
a
dictionary
->
Doc
.
page
val
name
:
'
a
dictionary
->
string
val
syntax
:
'
a
dictionary
->
Markdown
.
text
(** Publish the dictionnary. To more tag nor prefix can be added after.
If no [~tag] function is provided, registered values with tags
are used. *)
val
publish
:
'
a
dictionary
->
?
tag
:
(
'
a
->
'
a
tag
)
->
unit
->
(
module
S
with
type
t
=
'
a
)
(** Publish the dictionary. No more tag nor prefix can be added afterwards. If
no [~tag] function is provided, registered values with tags are used. *)
val
publish
:
'
a
dictionary
->
?
tag
:
(
'
a
->
'
a
tag
)
->
unit
->
(
module
S
with
type
t
=
'
a
)
end
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment