Skip to content

Commit ef75921

Browse files
minor line editing
1 parent 6801541 commit ef75921

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

data/tutorials/language/1ms_00_modules.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ val hello : unit -> unit
158158
(** [hello ()] displays a greeting message. *)
159159
```
160160

161-
**Note**: The double asterisk at the beginning of the comment indicates a
161+
**Note**: The double asterisk at the beginning indicates a
162162
comment meant for API documentation tools, such as
163163
[`odoc`](https://github.com/ocaml/odoc). It is a good habit to document `.mli`
164164
files using the format supported by this tool.
@@ -170,7 +170,7 @@ The file `delhi.ml` defines the program calling `Cairo`:
170170
let () = Cairo.hello ()
171171
```
172172

173-
Update the `dune` file to allow the compilation of this example aside from the
173+
Update the `dune` file to allow this example's compilation aside from the
174174
previous one.
175175
<!-- $MDX dir=examples -->
176176
```lisp
@@ -240,7 +240,7 @@ Update file `dune`:
240240
(library (name exeter) (modules exeter) (modes byte))
241241
```
242242

243-
Run the `dune utop` command, it triggers `Exeter`'s compilation, launches `utop` and loads `Exeter`.
243+
Run the `dune utop` command. This triggers `Exeter`'s compilation, launches `utop`, and loads `Exeter`.
244244
```ocaml
245245
# open Exeter;;
246246
@@ -254,7 +254,7 @@ Type `aleph` is public. Values can be created or accessed.
254254
Unknown element.
255255
```
256256

257-
Type `bet` is private, it is not available outside of the implementation where it is defined, here `Exeter`.
257+
Type `bet` is private. It is not available outside of the implementation where it is defined, here `Exeter`.
258258
```ocaml
259259
# #show gimel;;
260260
type gimel
@@ -272,7 +272,7 @@ val gimel_of_bool : bool -> gimel
272272
- : string = "Christine"
273273
```
274274

275-
Type `gimel` is _abstract_. Values can be created or manipulated, but only as function results or arguments. Only the provided functions `gimel_of_bool`, `gimel_flip`, and `gimel_to_string` or polymorphic functions can receive or return `gimel` values.
275+
Type `gimel` is _abstract_. Values can be created or manipulated, but only as function results or arguments. Just the provided functions `gimel_of_bool`, `gimel_flip`, and `gimel_to_string` or polymorphic functions can receive or return `gimel` values.
276276
```ocaml
277277
# #show dalet;;
278278
type dalet = private Dennis of int | Donald of string | Dorothy
@@ -318,12 +318,12 @@ let () =
318318
Florence.print_goodbye ()
319319
```
320320

321-
Definitions from a submodule are access by chaining module names, here
321+
Definitions from a submodule are accessed by chaining module names, here
322322
`Florence.Hello.print`.
323323

324-
### Submodule with Signatures
324+
### Submodule With Signatures
325325

326-
To define an interface to a submodule we can provide a _module signature_. This
326+
To define an interface to a submodule, we can provide a _module signature_. This
327327
is done in this second version of the `florence.ml` file:
328328
```ocaml
329329
module Hello : sig
@@ -354,9 +354,9 @@ end
354354
let print_goodbye () = print_endline "Goodbye"
355355
```
356356

357-
First, we define a `module type` called `HelloType` which defines the same module interface as previously. Instead of providing the signature when defining the `Hello` module, we use the `HelloType` module type.
357+
First, we define a `module type` called `HelloType`, which defines the same module interface as before. Instead of providing the signature when defining the `Hello` module, we use the `HelloType` module type.
358358

359-
This allows writing interfaces shared by several modules. An implementation satisfies any module type listing some of its contents. This implies a module may have several types and there is a subtyping relationship between module types.
359+
This allows writing interfaces shared by several modules. An implementation satisfies any module type listing some of its contents. This implies a module may have several types and that there is a subtyping relationship between module types.
360360

361361
## Module Manipulation
362362

0 commit comments

Comments
 (0)