Skip to content

Commit

Permalink
Auto merge of #16680 - lnicola:salsa-doc-test, r=Veykril
Browse files Browse the repository at this point in the history
internal: Remove salsa compile_fail tests

I can't figure out how to reproduce them, but hopefully fixes these:

![image](https://github.com/rust-lang/rust-analyzer/assets/308347/462dbfc3-5414-42fd-b81d-a3d699fa9a8d)
  • Loading branch information
bors committed Feb 26, 2024
2 parents 40bf8bf + 1ef7a99 commit f7f63cc
Showing 1 changed file with 2 additions and 23 deletions.
25 changes: 2 additions & 23 deletions crates/salsa/salsa-macros/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -93,29 +93,8 @@ mod query_group;
/// ## Attribute combinations
///
/// Some attributes are mutually exclusive. For example, it is an error to add
/// multiple storage specifiers:
///
/// ```compile_fail
/// # use salsa_macros as salsa;
/// #[salsa::query_group]
/// trait CodegenDatabase {
/// #[salsa::input]
/// #[salsa::memoized]
/// fn my_query(&self, input: u32) -> u64;
/// }
/// ```
///
/// It is also an error to annotate a function to `invoke` on an `input` query:
///
/// ```compile_fail
/// # use salsa_macros as salsa;
/// #[salsa::query_group]
/// trait CodegenDatabase {
/// #[salsa::input]
/// #[salsa::invoke(typeck::my_query)]
/// fn my_query(&self, input: u32) -> u64;
/// }
/// ```
/// multiple storage specifiers or to annotate a function to `invoke` on an
/// `input` query.
#[proc_macro_attribute]
pub fn query_group(args: TokenStream, input: TokenStream) -> TokenStream {
query_group::query_group(args, input)
Expand Down

0 comments on commit f7f63cc

Please sign in to comment.