about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorBenjamin Brittain <bwb@google.com>2018-07-29 17:20:11 -0700
committerBenjamin Brittain <bwb@google.com>2018-07-29 17:20:21 -0700
commit46b241004dbc4d6f77e81868304af4e79df9fe6f (patch)
tree09aaefd8ecec315e48b128a564ebf7affc90e3df /src
parentfedde3790c32c4956b06ae45699f0f76b4502865 (diff)
fix nits
Diffstat (limited to 'src')
-rw-r--r--src/items.rs10
-rw-r--r--src/utils.rs4
2 files changed, 7 insertions, 7 deletions
diff --git a/src/items.rs b/src/items.rs
index 47e35fb101d..b352294d3f3 100644
--- a/src/items.rs
+++ b/src/items.rs
@@ -164,7 +164,7 @@ pub struct FnSig<'a> {
     decl: &'a ast::FnDecl,
     generics: &'a ast::Generics,
     abi: abi::Abi,
-    asyncness: ast::IsAsync,
+    is_async: ast::IsAsync,
     constness: ast::Constness,
     defaultness: ast::Defaultness,
     unsafety: ast::Unsafety,
@@ -181,7 +181,7 @@ impl<'a> FnSig<'a> {
             decl,
             generics,
             abi: abi::Abi::Rust,
-            asyncness: ast::IsAsync::NotAsync,
+            is_async: ast::IsAsync::NotAsync,
             constness: ast::Constness::NotConst,
             defaultness: ast::Defaultness::Final,
             unsafety: ast::Unsafety::Normal,
@@ -195,7 +195,7 @@ impl<'a> FnSig<'a> {
     ) -> FnSig<'a> {
         FnSig {
             unsafety: method_sig.header.unsafety,
-            asyncness: method_sig.header.asyncness,
+            is_async: method_sig.header.asyncness,
             constness: method_sig.header.constness.node,
             defaultness: ast::Defaultness::Final,
             abi: method_sig.header.abi,
@@ -217,7 +217,7 @@ impl<'a> FnSig<'a> {
                 generics,
                 abi: fn_header.abi,
                 constness: fn_header.constness.node,
-                asyncness: fn_header.asyncness,
+                is_async: fn_header.asyncness,
                 defaultness,
                 unsafety: fn_header.unsafety,
                 visibility: visibility.clone(),
@@ -241,7 +241,7 @@ impl<'a> FnSig<'a> {
         result.push_str(format_defaultness(self.defaultness));
         result.push_str(format_constness(self.constness));
         result.push_str(format_unsafety(self.unsafety));
-        result.push_str(format_asyncness(self.asyncness));
+        result.push_str(format_async(self.is_async));
         result.push_str(&format_abi(
             self.abi,
             context.config.force_explicit_abi(),
diff --git a/src/utils.rs b/src/utils.rs
index 3dbffd6d175..5f92255e79c 100644
--- a/src/utils.rs
+++ b/src/utils.rs
@@ -82,8 +82,8 @@ pub fn format_visibility(context: &RewriteContext, vis: &Visibility) -> Cow<'sta
 }
 
 #[inline]
-pub fn format_asyncness(asyncness: ast::IsAsync) -> &'static str {
-    match asyncness {
+pub fn format_async(is_async: ast::IsAsync) -> &'static str {
+    match is_async {
         ast::IsAsync::Async { .. } => "async ",
         ast::IsAsync::NotAsync => "",
     }