Skip to content

Commit

Permalink
Fixed expected_one_let_bind_got_none test in leptos_macro
Browse files Browse the repository at this point in the history
  • Loading branch information
Ar4ys committed Feb 25, 2024
1 parent 46a068a commit 356a224
Showing 1 changed file with 3 additions and 86 deletions.
89 changes: 3 additions & 86 deletions leptos_macro/tests/ui/view/expected_one_let_bind_got_none.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -79,17 +79,10 @@ help: consider giving `props` an explicit type, where the placeholders `_` are s
| ++++++++++++++++++++++++++++

error[E0283]: type annotations needed for `ComponentProps<i32, C, RC>`
--> tests/ui/view/expected_one_let_bind_got_none.rs:34:9
--> tests/ui/view/expected_one_let_bind_got_none.rs:34:10
|
34 | <Component
| ^--------- required by a bound introduced by this call
| _________|
| |
35 | | data=0
36 | | >
37 | | <p/>
38 | | </Component>
| |____________________^
34 | <Component
| ^^^^^^^^^
|
= note: multiple `impl`s satisfying `_: Fn(i32)` found in the following crates: `alloc`, `core`:
- impl<A, F> std::ops::Fn<A> for &F
Expand All @@ -109,42 +102,6 @@ help: consider giving `props` an explicit type, where the type for type paramete
38 | </Component>: ComponentProps<i32, C, RC>
| ++++++++++++++++++++++++++++

error[E0283]: type annotations needed for `ComponentProps<i32, C, RC>`
--> tests/ui/view/expected_one_let_bind_got_none.rs:34:9
|
34 | / <Component
35 | | data=0
36 | | >
37 | | <p/>
38 | | </Component>
| |____________________^
|
= note: multiple `impl`s satisfying `_: Fn(i32)` found in the following crates: `alloc`, `core`:
- impl<A, F> std::ops::Fn<A> for &F
where A: Tuple, F: std::ops::Fn<A>, F: ?Sized;
- impl<Args, F, A> std::ops::Fn<Args> for Box<F, A>
where Args: Tuple, F: std::ops::Fn<Args>, A: Allocator, F: ?Sized;
note: required for `ComponentProps<i32, _, _>` to implement `leptos::Props`
--> tests/ui/view/expected_one_let_bind_got_none.rs:22:1
|
22 | #[component]
| ^^^^^^^^^^^^
...
25 | C: Fn(T) -> RC,
| ----------- unsatisfied trait bound introduced here
= note: required for `ComponentProps<i32, _, _>` to implement `PropsOrNoPropsBuilder`
= note: required for `&fn(ComponentProps<i32, _, _>) -> impl leptos::IntoView {Component::<i32, _, _>}` to implement `ComponentConstructor<ComponentProps<i32, _, _>>`
note: required by a bound in `component_view`
--> $WORKSPACE/leptos/src/lib.rs
|
| pub fn component_view<P>(f: impl ComponentConstructor<P>, props: P) -> View {
| ^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `component_view`
= note: this error originates in the attribute macro `component` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider giving `props` an explicit type, where the type for type parameter `C` is specified
|
38 | </Component>: ComponentProps<i32, C, RC>
| ++++++++++++++++++++++++++++

error[E0283]: type annotations needed for `Then<i32, C, RC>`
--> tests/ui/view/expected_one_let_bind_got_none.rs:43:13
|
Expand Down Expand Up @@ -318,43 +275,3 @@ help: consider giving `slot` an explicit type, where the type for type parameter
|
48 | </Then>: Then<i32, C, RC>
| ++++++++++++++++++

error[E0283]: type annotations needed for `Then<i32, C, RC>`
--> tests/ui/view/expected_one_let_bind_got_none.rs:43:13
|
42 | / <Slot>
43 | |/ <Then
44 | || slot
45 | || data=0
46 | || >
47 | || <p/>
48 | || </Then>
| ||___________________^
49 | | </Slot>
| |________________- required by a bound introduced by this call
|
= note: multiple `impl`s satisfying `_: Fn(i32)` found in the following crates: `alloc`, `core`:
- impl<A, F> std::ops::Fn<A> for &F
where A: Tuple, F: std::ops::Fn<A>, F: ?Sized;
- impl<Args, F, A> std::ops::Fn<Args> for Box<F, A>
where Args: Tuple, F: std::ops::Fn<Args>, A: Allocator, F: ?Sized;
note: required for `SlotProps<i32, _, _>` to implement `leptos::Props`
--> tests/ui/view/expected_one_let_bind_got_none.rs:13:1
|
13 | #[component]
| ^^^^^^^^^^^^
...
16 | C: Fn(T) -> RC,
| ----------- unsatisfied trait bound introduced here
= note: required for `SlotProps<i32, _, _>` to implement `PropsOrNoPropsBuilder`
= note: required for `&fn(SlotProps<i32, _, _>) -> impl leptos::IntoView {Slot::<i32, _, _>}` to implement `ComponentConstructor<SlotProps<i32, _, _>>`
note: required by a bound in `component_view`
--> $WORKSPACE/leptos/src/lib.rs
|
| pub fn component_view<P>(f: impl ComponentConstructor<P>, props: P) -> View {
| ^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `component_view`
= note: this error originates in the attribute macro `component` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider giving `slot` an explicit type, where the type for type parameter `C` is specified
|
48 | </Then>: Then<i32, C, RC>
| ++++++++++++++++++

0 comments on commit 356a224

Please sign in to comment.