diff options
| author | Yong He <yonghe@outlook.com> | 2022-11-18 12:37:27 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-11-18 12:37:27 -0800 |
| commit | d58e08f8237a1888ceaad53402d534679ea83b1a (patch) | |
| tree | e66838e0dc31fc12ebd7c1acecbb5060e8808366 /tests/diagnostics/autodiff.slang.expected | |
| parent | 0a050a439fa91b66f2020421d4fec3e60aed4112 (diff) | |
Data flow validation pass for diagnosing derivative loss. (#2523)
Diffstat (limited to 'tests/diagnostics/autodiff.slang.expected')
| -rw-r--r-- | tests/diagnostics/autodiff.slang.expected | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/diagnostics/autodiff.slang.expected b/tests/diagnostics/autodiff.slang.expected new file mode 100644 index 000000000..cd97bce76 --- /dev/null +++ b/tests/diagnostics/autodiff.slang.expected @@ -0,0 +1,14 @@ +result code = -1 +standard error = { +tests/diagnostics/autodiff.slang(20): error 38031: 'no_diff' can only be used to decorate a call. + float x1 = no_diff x; // invalid use of no_diff here. + ^~~~~~~ +tests/diagnostics/autodiff.slang(21): error 38032: use 'no_diff' on a call to a differentiable function has no meaning. + return no_diff f(x); // no_diff on a differentiable call has no meaning. + ^~~~~~~ +tests/diagnostics/autodiff.slang(26): error 38033: cannot use 'no_diff' in a non-differentiable function. + return no_diff nonDiff(x); // no_diff in a non-differentiable function + ^~~~~~~ +} +standard output = { +} |
