@@ -63,10 +63,16 @@ To generate Purescript .purs files from .proto files, run:
6363[nix-shell]$
6464```
6565
66−If you don't want to use Nix, then install the Purescript toolchain and *protoc*.
66+If you don't want to use Nix, then install the Purescript toolchain and `protoc`,
67+and add the executable script
68+[`bin/protoc-gen-purescript`](bin/protoc-gen-purescript)
69+to your `PATH`.
6770
6871## Writing programs with the generated code
6972
73+The code generator will use the `package` import statement in the `.proto` file
74+and the base `.proto` file name as the Purescript module name for that file.
75+
7076A message in a `shapes.proto` file declared as
7177
7278```
@@ -78,7 +84,8 @@ message Rectangle {
7884}
7985```
8086
81−will export these four names in a generated `shapes.Interproc.purs` file.
87+will export these four names from module `Interproc.Shapes` in a
88+generated `shapes.Interproc.purs` file.
8289
83901. A message data type
8491
@@ -86,6 +93,9 @@ will export these four names in a generated `shapes.Interproc.purs` file.
8693 newtype Rectangle = Rectangle { width :: Maybe Number, height :: Maybe Number }
8794 ```
8895
96+ The message data type will also include an `__unknown_fields` field which
97+ is required for conformance.
98+
89992. A message maker which constructs a message from a `Record`
90100 with some message fields
91101
@@ -93,7 +103,11 @@ will export these four names in a generated `shapes.Interproc.purs` file.
93103 mkRectangle :: forall r. Record r -> Rectangle
94104 ```
95105
96− All message fields are optional, and can be omitted from the `Record`. If we want the compiler to check that we've explicitly supplied all the fields,
106+ All message fields are optional, and can be elided when making a message.
107+ There are some extra type constraints, not shown here, which will cause a
108+ compiler error if we try to add a field which is not in the message data type.
109+
110+ If we want the compiler to check that we've explicitly supplied all the fields,
97111 then we can use the ordinary message data type constructor.
98112
991133. A message encoder which works with
@@ -235,10 +249,7 @@ The path to the protobuf definition which failed to parse will be included
235249in the `ParseError String` and delimited by `'/'`, something
236250like `"Message1 / string_field_1 / Invalid UTF8 encoding."`.
237251
238−### Imports
239−
240−The code generator will use the `package` statement in the `.proto` file
241−and the base file name as the Purescript module name for that file.
252+### Protobuf Imports
242253
243254The Protobuf
244255[`import`](https://developers.google.com/protocol-buffers/docs/proto3#importing_definitions)
@@ -251,10 +262,12 @@ statement in the imported file.
251262
252263For that reason, we can only use top-level
253264(not [nested](https://developers.google.com/protocol-buffers/docs/proto3#nested))
254−`message` and `enum` types from an `import`.
265+`message` and `enum` types from a Protobuf `import`.
266+
267+### PureScript Imports
255268
256269The generated Purescript code will usually have module imports which cause
257−the `purs` compiler to emit warnings. Sorry.
270+the `purs` compiler to emit warnings. We beg your pardon.
258271
259272## Nix derivation
260273