Commit graph

359 commits

Author SHA1 Message Date
Niko Matsakis
3add1337f6 create struct and fields 2019-01-21 10:59:11 -05:00
Niko Matsakis
7b6254924e first shot at parsing database-storage in syn 2019-01-21 10:59:11 -05:00
Niko Matsakis
d15be76350 move parenthesized to its own module 2019-01-21 10:59:11 -05:00
Niko Matsakis
d510b28fe2 move salsa::query_group code into its own module 2019-01-21 10:59:11 -05:00
Niko Matsakis
2c3450c885 bump release number to 0.10.0-alpha1 2019-01-17 05:41:07 -05:00
Niko Matsakis
85a637eb4f rename salsa_macros to salsa-macros 2019-01-17 05:28:42 -05:00
Niko Matsakis
8affc724c9 make the compile-fail test work 2019-01-17 05:27:20 -05:00
Niko Matsakis
0f577a2b10 generate an impl of the trait from procedural macro
Instead of generating

```rust
trait Query: GetQueryTable<Foo> {
    fn foo() { .. }
}
```

generate

```rust
trait Query {
}

impl<T> Query for T
where
    T: GetQueryTable<Foo>,
{
    fn foo() { .. }
}
```
2019-01-17 05:04:27 -05:00
Fabian Schuiki
93c30a953d make query_group macro procedural
Switch to a procedural implementation of the `query_group!` macro,
residing in the `components/salsa_macros` subcrate.

Allow the user to override the invoked function via `salsa::invoke(...)`
and the name of the generated query type via `salsa::query_type(...)`.

In all tests, replace the `salsa::query_group! { ... }` invocations with
the new attribute-style `#[salsa::query_group]` macro, and change them
to the new naming scheme for query types (`...Query`).

Update README, examples, and documentation.
2019-01-17 07:24:18 +01:00