Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Clippy For Rust 1.72 #3387

Merged
merged 2 commits into from
Aug 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/yew-macro/tests/html_macro_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ fn html_macro() {
element which can't have any children."
)]
fn dynamic_tags_catch_void_elements() {
html! {
let _ = html! {
<@{"br"}>
<span>{ "No children allowed" }</span>
</@>
Expand All @@ -25,7 +25,7 @@ fn dynamic_tags_catch_void_elements() {
#[test]
#[should_panic(expected = "a dynamic tag returned a tag name containing non ASCII characters: `❤`")]
fn dynamic_tags_catch_non_ascii() {
html! {
let _ = html! {
<@{"❤"}/>
};
}
Expand Down
4 changes: 2 additions & 2 deletions packages/yew/src/dom_bundle/btext.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,11 +156,11 @@ mod test {

#[test]
fn text_as_root() {
html! {
let _ = html! {
"Text Node As Root"
};

html! {
let _ = html! {
{ "Text Node As Root" }
};
}
Expand Down
2 changes: 1 addition & 1 deletion packages/yew/src/virtual_dom/key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ mod test {

#[test]
fn all_key_conversions() {
html! {
let _ = html! {
<key="string literal">
<img key={"String".to_owned()} />
<p key={Rc::<str>::from("rc")}></p>
Expand Down
1 change: 1 addition & 0 deletions packages/yew/src/virtual_dom/vnode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ use crate::AttrValue;

/// Bind virtual element to a DOM reference.
#[derive(Clone, PartialEq)]
#[must_use = "html does not do anything unless returned to Yew for rendering."]
pub enum VNode {
/// A bind between `VTag` and `Element`.
VTag(Box<VTag>),
Expand Down
Loading