diff --git a/docs/contributor/commits_pull_requests_and_merging.md b/docs/contributor/commits_pull_requests_and_merging.md index 3ab75c1a7..3bb043a28 100644 --- a/docs/contributor/commits_pull_requests_and_merging.md +++ b/docs/contributor/commits_pull_requests_and_merging.md @@ -12,7 +12,7 @@ When committing, it's often useful to use the `git add -p` workflow to decide on ### Conventional Commits -As of the [6202982](https://github.com/grain-lang/grain/commit/620298225faf35265e7285fe3d4d2c8dee72dba3) commit, Grain follows the [Conventional Commits (v1.0.0)](https://www.conventionalcommits.org/en/v1.0.0/) specification. Following this convention allows us to provide an automated release processs that also generates a detailed changelog. +As of the [6202982](https://github.com/grain-lang/grain/commit/620298225faf35265e7285fe3d4d2c8dee72dba3) commit, Grain follows the [Conventional Commits (v1.0.0)](https://www.conventionalcommits.org/en/v1.0.0/) specification. Following this convention allows us to provide an automated release process that also generates a detailed changelog. As described by the spec, our commit messages should be written as: diff --git a/docs/contributor/compiler_walkthrough.md b/docs/contributor/compiler_walkthrough.md index d6be8ed38..02d2c5d4e 100644 --- a/docs/contributor/compiler_walkthrough.md +++ b/docs/contributor/compiler_walkthrough.md @@ -50,7 +50,7 @@ The definition for the Grain AST (which we often refer to as the parsetree) can ## Well-formedness -This is just a fancy term for asking the question "does this program—for the most part—make sense?" In Grain, type identifers must always start with a capital letter, so there's a well-formedness check that enforces this. In general, we like to be as lenient as possible while parsing and provide helpful error messages from well-formedness checks. If a user writes a program like `type foo = ...`, it's much better to say `Error: 'foo' should be capitalized` rather than `Syntax error`. +This is just a fancy term for asking the question "does this program—for the most part—make sense?" In Grain, type identifiers must always start with a capital letter, so there's a well-formedness check that enforces this. In general, we like to be as lenient as possible while parsing and provide helpful error messages from well-formedness checks. If a user writes a program like `type foo = ...`, it's much better to say `Error: 'foo' should be capitalized` rather than `Syntax error`. You can find the Grain well-formedness checks in [parsing/well_formedness.re](https://github.com/grain-lang/grain/blob/main/compiler/src/parsing/well_formedness.re). @@ -68,7 +68,7 @@ After typechecking, we have more information about the program. We do a second w ## Linearization -In this step, we convert the typedtree into [A-normal Form](https://en.wikipedia.org/wiki/A-normal_form), or ANF. This purpose of this step is to create a linear set of expressions that could be performed in order from start to finish. For example, given the expression `foo(3 * 4, bar(5))`, we'd want to produce: +In this step, we convert the typedtree into [A-normal Form](https://en.wikipedia.org/wiki/A-normal_form), or ANF. The purpose of this step is to create a linear set of expressions that could be performed in order from start to finish. For example, given the expression `foo(3 * 4, bar(5))`, we'd want to produce: ```plaintext $arg1 := 3 * 4 diff --git a/docs/contributor/memory_management.md b/docs/contributor/memory_management.md index de54e0af5..1b9ed4dd9 100644 --- a/docs/contributor/memory_management.md +++ b/docs/contributor/memory_management.md @@ -119,7 +119,7 @@ Note that `load_swap` is one of the aforementioned exceptions which does not `in **References are callee-owned.** This has a couple of implications: - If a function is called with an argument, it is the responsibility of that function to `decRef` that argument. -- If a value is passed to a function with a reference count of `n`, when it returns, it will have the a reference count of `n-1` (unless it was stored in an external location, in which case the reference count may be higher). +- If a value is passed to a function with a reference count of `n`, when it returns, it will have the reference count of `n-1` (unless it was stored in an external location, in which case the reference count may be higher). ## Disabling the Garbage Collector diff --git a/docs/contributor/string.md b/docs/contributor/string.md index 4a88195c9..3b11e4c3f 100644 --- a/docs/contributor/string.md +++ b/docs/contributor/string.md @@ -55,12 +55,12 @@ searching and comparing strings. Strings in Grain are not normalized. JavaScript strings are not encoded in UTF-8. JavaScript uses UCS-2 with unpaired surrogate codepoints. Each codepoint is -represented by two bytes. A surrograte pair is a pair of codepoints used to -represent a codepoint greater than U+FFFF. DOMString is the same but with a -replacement character, U+FFFD, for unpaired surrogate codepoints. A USVString -is the same but without unpaired surrogate codepoints. A CSSOMString is the +represented by two bytes. A surrogate pair is a pair of codepoints used to +represent a codepoint greater than U+FFFF. DOMString is the same but with a +replacement character, U+FFFD, for unpaired surrogate codepoints. A USVString +is the same but without unpaired surrogate codepoints. A CSSOMString is the same as a DOMString. A JavaScript string containing one or more unpaired surrogate codepoints is not -a valid UTF-16 string. USVString, DOMString and CSSOMString are valid UTF-16 +a valid UTF-16 string. USVString, DOMString and CSSOMString are valid UTF-16 strings. The encoder converts to USVString.