diff --git a/compiler/ic/packed_ast.nim b/compiler/ic/packed_ast.nim index 6fadde17c9..17beda2c18 100644 --- a/compiler/ic/packed_ast.nim +++ b/compiler/ic/packed_ast.nim @@ -86,7 +86,7 @@ type typeInst*: PackedItemId nonUniqueId*: int32 - PackedNode* = object # 20 bytes + PackedNode* = object # 28 bytes kind*: TNodeKind flags*: TNodeFlags operand*: int32 # for kind in {nkSym, nkSymDef}: SymId diff --git a/doc/destructors.rst b/doc/destructors.rst index 01e2d2ee9b..c93fcabe18 100644 --- a/doc/destructors.rst +++ b/doc/destructors.rst @@ -277,7 +277,7 @@ inference. But it has to be enabled via `--sinkInference:on`, either on the command line or via a `push` pragma. To enable it for a section of code, one can -use `{.push sinkInference: on.}`...`{.pop.}`. +use `{.push sinkInference: on.}` ... `{.pop.}`. The `.nosinks`:idx: pragma can be used to disable this inference for a single routine: @@ -661,12 +661,12 @@ There is no copy during assigning operations. y[0] = 'h' # copy The program above shows when the copy operations happen. -When mutating the variable `y`, the Nim compiler creates a fresh copy of `x`, -the variable `y` won't point to the string literal anymore. -Instead it points to the copy of `x` of which the memory can be mutated +When mutating the variable `y`, the Nim compiler creates a fresh copy of `x`, +the variable `y` won't point to the string literal anymore. +Instead it points to the copy of `x` of which the memory can be mutated and the variable `y` becomes a mutable string. -.. Note:: The abstraction fails for `addr x` because whether the address is going to be used for mutations is unknown. +.. Note:: The abstraction fails for `addr x` because whether the address is going to be used for mutations is unknown. Let's look at a silly example demonstrating this behaviour: