mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-19 14:00:35 +00:00
Update manual.md (#20321)
* Update manual.md add explanation for $#. * Update manual.md add explanation.
This commit is contained in:
@@ -7855,8 +7855,9 @@ The `codegenDecl` pragma can be used to directly influence Nim's code
|
||||
generator. It receives a format string that determines how the variable
|
||||
or proc is declared in the generated code.
|
||||
|
||||
For variables, $1 in the format string represents the type of the variable
|
||||
and $2 is the name of the variable.
|
||||
For variables, $1 in the format string represents the type of the variable,
|
||||
$2 is the name of the variable, and each appearance of $# represents $1/$2
|
||||
respectively according to its position.
|
||||
|
||||
The following Nim code:
|
||||
|
||||
@@ -7872,7 +7873,8 @@ will generate this C code:
|
||||
```
|
||||
|
||||
For procedures, $1 is the return type of the procedure, $2 is the name of
|
||||
the procedure, and $3 is the parameter list.
|
||||
the procedure, $3 is the parameter list, and each appearance of $# represents
|
||||
$1/$2/$3 respectively according to its position.
|
||||
|
||||
The following nim code:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user