mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-26 00:34:06 +00:00
d7d6238b23
This is consistent with all other diagnostics I could find containing features and enables the use of `DiagSymbolList` for generalizing diagnostics for unstable library features to multiple features.
18 lines
645 B
Rust
18 lines
645 B
Rust
//@ revisions: has_support no_support
|
|
//@[no_support] ignore-enzyme
|
|
//@[has_support] needs-enzyme
|
|
|
|
// This checks that without enabling the autodiff feature, we can't import std::autodiff::autodiff;
|
|
|
|
#![crate_type = "lib"]
|
|
|
|
use std::autodiff::autodiff;
|
|
//[has_support]~^ ERROR use of unstable library feature `autodiff`
|
|
//[no_support]~^^ ERROR use of unstable library feature `autodiff`
|
|
|
|
#[autodiff(dfoo, Reverse)]
|
|
//[has_support]~^ ERROR use of unstable library feature `autodiff` [E0658]
|
|
//[no_support]~^^ ERROR use of unstable library feature `autodiff` [E0658]
|
|
//[no_support]~| ERROR this rustc version does not support autodiff
|
|
fn foo() {}
|