]> git.lizzy.rs Git - rust.git/commitdiff
end return statements and void expressions with a semicolon
authorljedrz <ljedrz@gmail.com>
Tue, 16 Oct 2018 09:14:10 +0000 (11:14 +0200)
committerljedrz <ljedrz@gmail.com>
Tue, 16 Oct 2018 09:14:10 +0000 (11:14 +0200)
src/librustc_codegen_llvm/debuginfo/metadata.rs
src/librustc_codegen_llvm/debuginfo/source_loc.rs

index 6dcca65a73601e8f7aced9df2d375b419dd4f934..163a8b91f4c4ff90c7e0f61479b8fc3bb92a839b 100644 (file)
@@ -164,7 +164,7 @@ fn get_unique_type_id_of_type<'a>(&mut self, cx: &CodegenCx<'a, 'tcx>,
                                       type_: Ty<'tcx>) -> UniqueTypeId {
         // Let's see if we already have something in the cache
         if let Some(unique_type_id) = self.type_to_unique_id.get(&type_).cloned() {
-            return unique_type_id
+            return unique_type_id;
         }
         // if not, generate one
 
@@ -290,7 +290,7 @@ macro_rules! return_if_metadata_created_in_meantime {
             .borrow()
             .find_metadata_for_unique_id($unique_type_id)
         {
-            return MetadataCreationResult::new(metadata, true)
+            return MetadataCreationResult::new(metadata, true);
         }
     )
 }
@@ -552,7 +552,7 @@ pub fn type_metadata(
                     .borrow()
                     .find_metadata_for_unique_id(unique_type_id)
                 {
-                    return Err(metadata)
+                    return Err(metadata);
                 }
 
                 Ok(MetadataCreationResult::new(pointer_type_metadata(cx, t, pointee_metadata),
@@ -612,7 +612,7 @@ pub fn type_metadata(
                .borrow()
                .find_metadata_for_unique_id(unique_type_id)
             {
-                return metadata
+                return metadata;
             }
 
             // This is actually a function pointer, so wrap it in pointer DI
@@ -1477,7 +1477,7 @@ fn prepare_enum_metadata(
     };
 
     if let (&layout::Abi::Scalar(_), Some(discr)) = (&layout.abi, discriminant_type_metadata) {
-        return FinalMetadata(discr)
+        return FinalMetadata(discr);
     }
 
     let (enum_type_size, enum_type_align) = layout.size_and_align();
index 405cffdefa285b865ef4cd86d6930e6e26b5133e..60ebcb888166ff96bb0193f05edf153b7551d9c5 100644 (file)
@@ -57,7 +57,7 @@ pub fn set_source_location(
 /// first real statement/expression of the function is codegened.
 pub fn start_emitting_source_locations(dbg_context: &FunctionDebugContext<'ll>) {
     if let FunctionDebugContext::RegularContext(ref data) = *dbg_context {
-        data.source_locations_enabled.set(true)
+        data.source_locations_enabled.set(true);
     }
 }