Skip to content

Commit 749b470

Browse files
authored
Merge pull request #298 from chanijjani/doc-rust-target
Update the Target Description web page
2 parents 4783c7d + 53d115f commit 749b470

File tree

2 files changed

+14
-24
lines changed

2 files changed

+14
-24
lines changed

docs/reference/target-declaration.mdx

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ rs={
104104
build-type: <Debug, Release, RelWithDebInfo, or MinSizeRel>,
105105
cargo-features: <array of strings>,
106106
cargo-dependencies: <list of key-value pairs>,
107-
export-dependency-graph: <true or false>,
108107
rust-include: <array of strings>,
109108
single-file-project: <true or false>,
110109
single-threaded: <true or false>,
@@ -380,10 +379,10 @@ This option takes a path as string argument to a folder containing an alternativ
380379
<ShowIf c py ts>
381380
This target does not support the `export-dependency-graph` target option.
382381
</ShowIf>
383-
<ShowIf cpp rs>
382+
<ShowIf cpp>
384383
This parameter takes arguments `true` or `false` to specify whether the compiled binary will export its internal dependency graph as a dot graph when executed. This is a debugging utility.
385384
<ShowOnly rs>
386-
If a [CLI](#command-line-arguments) is generated, the target property is ignored, and the user should instead use the `--export-graph` flag of the generated program.
385+
This feature works when a [CLI](#command-line-arguments) option is enabled and the user use the `--export-graph` flag of the generated program.
387386
</ShowOnly>
388387
</ShowIf>
389388
</ShowIfs>
@@ -477,10 +476,10 @@ The `logging` option is one of `ERROR`, `WARN`, `INFO`, `LOG` or `DEBUG`. It spe
477476
## no-compile
478477

479478
<ShowIfs>
480-
<ShowIf ts rs >
479+
<ShowIf ts>
481480
This target does not support the `no-compile` target option.
482481
</ShowIf>
483-
<ShowIf c cpp py>
482+
<ShowIf c cpp py rs>
484483
If true, then do not invoke a target language compiler nor cmake. Just generate code.
485484
</ShowIf>
486485
</ShowIfs>
@@ -534,19 +533,16 @@ This argument takes a string (with quotation marks) containing any tag, branch n
534533
This target does not support the `rust-include` target option.
535534
</ShowIf>
536535
<ShowIf rs>
537-
This specifies a set of Rust modules in the generated project. See [Linking support files](#linking-support-files).
536+
This specifies a set of Rust modules in the generated project.
538537
</ShowIf>
539538
</ShowIfs>
540539

541540
## scheduler
542541

543542
<ShowIfs>
544-
<ShowIf c cpp py ts >
543+
<ShowIf c cpp py rs ts >
545544
This target does not support the `scheduler` target option.
546545
</ShowIf>
547-
<ShowIf rs>
548-
This specifies the scheduler to use. See[Target Language Details](<../reference/target-language-details.mdx#scheduler-target-property>).
549-
</ShowIf>
550546
</ShowIfs>
551547

552548
## single-file-project
@@ -556,7 +552,7 @@ This specifies the scheduler to use. See[Target Language Details](<../reference/
556552
This target does not support the `single-file-project` target option.
557553
</ShowIf>
558554
<ShowIf rs>
559-
If true, enables [single-file project layout](#single-file-layout).
555+
If true, only main.rs is generated instead of multiple rust source files.
560556
</ShowIf>
561557
</ShowIfs>
562558

@@ -732,7 +728,6 @@ The generated executable may feature a command-line interface (CLI), if it uses
732728
- `--timeout <time value>`: override the default timeout mentioned as a target property. The syntax for times is just like the LF one (e.g. `1msec`, `"2 seconds"`).
733729
- `--workers <number>`: override the default worker count mentioned as a target property. This option is **ignored** unless the runtime crate has been built with the feature `parallel-runtime`.
734730
- `--export-graph`: export the dependency graph (corresponds to `export-dependency-graph` target property). This is a flag, i.e., absent means false, present means true. This means the value of the target property is ignored and not used as default.
735-
- `--log-level`: corresponds to the `logging` target property, but note that the levels have different meanings, and the target property is ignored. See [Logging levels](#logging-levels).
736731
- parameters of the main reactor are translated to CLI parameters.
737732
- Each LF parameter named `param` corresponds to a CLI parameter named `--main-param`. Underscores in the LF parameter name are replaced by hyphens.
738733
- The type of each parameters must implement the trait [`FromStr`](https://doc.rust-lang.org/std/str/trait.FromStr.html).

versioned_docs/version-0.9.0/reference/target-declaration.mdx

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ rs={
104104
build-type: <Debug, Release, RelWithDebInfo, or MinSizeRel>,
105105
cargo-features: <array of strings>,
106106
cargo-dependencies: <list of key-value pairs>,
107-
export-dependency-graph: <true or false>,
108107
rust-include: <array of strings>,
109108
single-file-project: <true or false>,
110109
single-threaded: <true or false>,
@@ -380,10 +379,10 @@ This option takes a path as string argument to a folder containing an alternativ
380379
<ShowIf c py ts>
381380
This target does not support the `export-dependency-graph` target option.
382381
</ShowIf>
383-
<ShowIf cpp rs>
382+
<ShowIf cpp>
384383
This parameter takes arguments `true` or `false` to specify whether the compiled binary will export its internal dependency graph as a dot graph when executed. This is a debugging utility.
385384
<ShowOnly rs>
386-
If a [CLI](#command-line-arguments) is generated, the target property is ignored, and the user should instead use the `--export-graph` flag of the generated program.
385+
This feature works when a [CLI](#command-line-arguments) option is enabled and the user use the `--export-graph` flag of the generated program.
387386
</ShowOnly>
388387
</ShowIf>
389388
</ShowIfs>
@@ -477,10 +476,10 @@ The `logging` option is one of `ERROR`, `WARN`, `INFO`, `LOG` or `DEBUG`. It spe
477476
## no-compile
478477

479478
<ShowIfs>
480-
<ShowIf ts rs >
479+
<ShowIf ts>
481480
This target does not support the `no-compile` target option.
482481
</ShowIf>
483-
<ShowIf c cpp py>
482+
<ShowIf c cpp py rs>
484483
If true, then do not invoke a target language compiler nor cmake. Just generate code.
485484
</ShowIf>
486485
</ShowIfs>
@@ -534,19 +533,16 @@ This argument takes a string (with quotation marks) containing any tag, branch n
534533
This target does not support the `rust-include` target option.
535534
</ShowIf>
536535
<ShowIf rs>
537-
This specifies a set of Rust modules in the generated project. See [Linking support files](#linking-support-files).
536+
This specifies a set of Rust modules in the generated project.
538537
</ShowIf>
539538
</ShowIfs>
540539

541540
## scheduler
542541

543542
<ShowIfs>
544-
<ShowIf c cpp py ts >
543+
<ShowIf c cpp py rs ts >
545544
This target does not support the `scheduler` target option.
546545
</ShowIf>
547-
<ShowIf rs>
548-
This specifies the scheduler to use. See[Target Language Details](<../reference/target-language-details.mdx#scheduler-target-property>).
549-
</ShowIf>
550546
</ShowIfs>
551547

552548
## single-file-project
@@ -556,7 +552,7 @@ This specifies the scheduler to use. See[Target Language Details](<../reference/
556552
This target does not support the `single-file-project` target option.
557553
</ShowIf>
558554
<ShowIf rs>
559-
If true, enables [single-file project layout](#single-file-layout).
555+
If true, only main.rs is generated instead of multiple rust source files.
560556
</ShowIf>
561557
</ShowIfs>
562558

@@ -732,7 +728,6 @@ The generated executable may feature a command-line interface (CLI), if it uses
732728
- `--timeout <time value>`: override the default timeout mentioned as a target property. The syntax for times is just like the LF one (e.g. `1msec`, `"2 seconds"`).
733729
- `--workers <number>`: override the default worker count mentioned as a target property. This option is **ignored** unless the runtime crate has been built with the feature `parallel-runtime`.
734730
- `--export-graph`: export the dependency graph (corresponds to `export-dependency-graph` target property). This is a flag, i.e., absent means false, present means true. This means the value of the target property is ignored and not used as default.
735-
- `--log-level`: corresponds to the `logging` target property, but note that the levels have different meanings, and the target property is ignored. See [Logging levels](#logging-levels).
736731
- parameters of the main reactor are translated to CLI parameters.
737732
- Each LF parameter named `param` corresponds to a CLI parameter named `--main-param`. Underscores in the LF parameter name are replaced by hyphens.
738733
- The type of each parameters must implement the trait [`FromStr`](https://doc.rust-lang.org/std/str/trait.FromStr.html).

0 commit comments

Comments
 (0)