Update to edition 2021 (#2354)

* cargo fix --edition

* change edition="2018" to edition="2021" in Cargo.toml
This commit is contained in:
Muhammad Hamza 2022-01-12 19:22:00 +05:00 committed by GitHub
parent 600f508db2
commit f05ba4152c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
41 changed files with 49 additions and 49 deletions

View File

@ -2,7 +2,7 @@
name = "agents"
version = "0.1.0"
authors = ["Denis Kolodin <deniskolodin@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "boids"
version = "0.1.0"
authors = ["motoki saito <stmtk13044032@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

View File

@ -1,7 +1,7 @@
[package]
name = "contexts"
version = "0.1.0"
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "counter"
version = "0.1.1"
authors = ["Denis Kolodin <deniskolodin@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "dyn_create_destroy_apps"
version = "0.1.0"
authors = ["Nicklas Warming Jacobsen <nicklaswj@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "file_upload"
version = "0.1.0"
authors = ["Denis Kolodin <deniskolodin@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "function_memory_game"
version = "0.1.0"
authors = ["Howard.Zuo <leftstick@qq.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "function_todomvc"
version = "0.1.0"
authors = ["Drew Hutton <drew.hutton@pm.me>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "futures"
version = "0.1.0"
authors = ["Henry Zimmerman <zimhen7@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -6,7 +6,7 @@ authors = [
"Ilya Bogdanov <fumlead@gmail.com",
"Junjie Huang <huangjj.27@qq.com>"
]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "inner_html"
version = "0.1.0"
authors = ["Garrett Berg <vitiral@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "js_callback"
version = "0.1.0"
authors = ["Scott Steele <scottlsteele@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "keyed_list"
version = "0.1.0"
authors = ["Thomas Lacroix <toto.rigolo@free.fr>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "mount_point"
version = "0.1.0"
authors = ["Ben Berman <ben@standardbots.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "nested_list"
version = "0.1.0"
authors = ["Justin Starry <justin.starry@icloud.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "node_refs"
version = "0.1.0"
authors = ["Justin Starry <justin.starry@icloud.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "password_strength"
version = "0.1.0"
authors = ["Philip Peterson <pc.peterso@gmail.com>"]
edition = "2018"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]

View File

@ -2,7 +2,7 @@
name = "portals"
version = "0.1.0"
authors = ["Martin Molzer <worldsbegin@gmx.de>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -1,7 +1,7 @@
[package]
name = "router"
version = "0.1.0"
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -1,7 +1,7 @@
[package]
name = "simple_ssr"
version = "0.1.0"
edition = "2018"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

View File

@ -1,7 +1,7 @@
[package]
name = "suspense"
version = "0.1.0"
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

View File

@ -2,7 +2,7 @@
name = "timer"
version = "0.1.0"
authors = ["Denis Kolodin <deniskolodin@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "todomvc"
version = "0.1.0"
authors = ["Denis Kolodin <deniskolodin@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "two_apps"
version = "0.1.0"
authors = ["Denis Kolodin <deniskolodin@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -1,7 +1,7 @@
[package]
name = "yew-worker-fib"
version = "0.1.0"
edition = "2018"
edition = "2021"
authors = ["Shrey Somaiya", "Zac Kologlu"]
[lib]

View File

@ -2,7 +2,7 @@
name = "webgl"
version = "0.1.0"
authors = ["Miklós Tusz <mdtusz@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
[dependencies]

View File

@ -2,7 +2,7 @@
name = "yew-agent"
version = "0.1.0"
authors = ["Hamza <muhammadhamza1311@gmail.com>"]
edition = "2018"
edition = "2021"
readme = "../../README.md"
description = "Agents for Yew"
license = "MIT OR Apache-2.0"

View File

@ -1,7 +1,7 @@
[package]
name = "yew-macro"
version = "0.19.3"
edition = "2018"
edition = "2021"
authors = ["Justin Starry <justin@yew.rs>"]
repository = "https://github.com/yewstack/yew"
homepage = "https://github.com/yewstack/yew"

View File

@ -65,19 +65,19 @@ impl ToTokens for PropsBuilder<'_> {
#(impl #step_trait for #step_names {})*
#[doc(hidden)]
#vis struct #builder_name#step_generics
#vis struct #builder_name #step_generics
#where_clause
{
wrapped: ::std::boxed::Box<#wrapper_name#ty_generics>,
wrapped: ::std::boxed::Box<#wrapper_name #ty_generics>,
_marker: ::std::marker::PhantomData<#step_generic_param>,
}
#impl_steps
impl#impl_generics #builder_name<#generic_args> #where_clause {
impl #impl_generics #builder_name<#generic_args> #where_clause {
#[doc(hidden)]
#vis fn build(self) -> #props_name#ty_generics {
#props_name#turbofish_generics {
#vis fn build(self) -> #props_name #ty_generics {
#props_name #turbofish_generics {
#(#set_fields)*
}
}
@ -190,7 +190,7 @@ impl PropsBuilder<'_> {
token_stream.extend(quote! {
#( #extra_attrs )*
impl#impl_generics #builder_name<#current_step_arguments> #where_clause {
impl #impl_generics #builder_name<#current_step_arguments> #where_clause {
#(#optional_prop_fn)*
#(#required_prop_fn)*
}

View File

@ -105,7 +105,7 @@ impl ToTokens for DerivePropsInput {
// The properties trait has a `builder` method which creates the props builder
let (impl_generics, ty_generics, where_clause) = generics.split_for_impl();
let properties = quote! {
impl#impl_generics ::yew::html::Properties for #props_name#ty_generics #where_clause {
impl #impl_generics ::yew::html::Properties for #props_name #ty_generics #where_clause {
type Builder = #builder_name<#builder_generic_args>;
fn builder() -> Self::Builder {

View File

@ -27,15 +27,15 @@ impl ToTokens for PropsWrapper<'_> {
let wrapper = quote! {
#(#extra_attrs)*
struct #wrapper_name#generics
struct #wrapper_name #generics
#where_clause
{
#(#wrapper_field_defs)*
}
impl#impl_generics ::std::default::Default for #wrapper_name#ty_generics #where_clause {
impl #impl_generics ::std::default::Default for #wrapper_name #ty_generics #where_clause {
fn default() -> Self {
#wrapper_name#turbofish_generics {
#wrapper_name #turbofish_generics {
#(#wrapper_default_setters)*
}
}

View File

@ -88,8 +88,8 @@ impl ToTokens for HtmlDashedName {
let HtmlDashedName { name, extended } = self;
let dashes = extended.iter().map(|(dash, _)| quote! {#dash});
let idents = extended.iter().map(|(_, ident)| quote! {#ident});
let extended = quote! { #(#dashes#idents)* };
tokens.extend(quote! { #name#extended });
let extended = quote! { #(#dashes #idents)* };
tokens.extend(quote! { #name #extended });
}
}

View File

@ -498,7 +498,7 @@ impl Parse for DynamicName {
impl ToTokens for DynamicName {
fn to_tokens(&self, tokens: &mut TokenStream) {
let Self { at, expr } = self;
tokens.extend(quote! {#at#expr});
tokens.extend(quote! {#at #expr});
}
}

View File

@ -72,7 +72,7 @@ impl ToTokens for HtmlList {
let spanned = {
let open = open.to_spanned();
let close = close.to_spanned();
quote! { #open#close }
quote! { #open #close }
};
tokens.extend(quote_spanned! {spanned.span()=>

View File

@ -145,6 +145,6 @@ impl TagTokens {
/// This is to work around the limitation of being unable to manually join spans on stable.
pub fn to_spanned(&self) -> impl ToTokens {
let Self { lt, gt, .. } = self;
quote! {#lt#gt}
quote! {#lt #gt}
}
}

View File

@ -30,7 +30,7 @@ impl Parse for BaseExpr {
impl ToTokens for BaseExpr {
fn to_tokens(&self, tokens: &mut TokenStream) {
let BaseExpr { dot2, expr } = self;
tokens.extend(quote! { #dot2#expr });
tokens.extend(quote! { #dot2 #expr });
}
}

View File

@ -2,7 +2,7 @@
name = "yew-router-macro"
version = "0.16.0"
authors = ["Hamza <muhammadhamza1311@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
description = "Contains macros used with yew-router"
repository = "https://github.com/yewstack/yew"

View File

@ -2,7 +2,7 @@
name = "yew-router"
version = "0.16.0"
authors = ["Hamza <muhammadhamza1311@gmail.com>"]
edition = "2018"
edition = "2021"
license = "MIT OR Apache-2.0"
readme = "README.md"
keywords = ["web", "yew", "router"]

View File

@ -1,7 +1,7 @@
[package]
name = "yew"
version = "0.19.3"
edition = "2018"
edition = "2021"
authors = [
"Denis Kolodin <deniskolodin@gmail.com>",
"Justin Starry <justin@yew.rs>",

View File

@ -2,7 +2,7 @@
name = "changelog"
version = "0.1.0"
authors = ["Cecile Tonglet <cecile.tonglet@cecton.com>"]
edition = "2018"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

View File

@ -1,7 +1,7 @@
[package]
name = "website-test"
version = "0.1.0"
edition = "2018"
edition = "2021"
build = "build.rs"
publish = false