Skip to content

Commit a3f05ce

Browse files
authored
clean up get_vtable's doc comment
1 parent a5dbf8a commit a3f05ce

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/librustc_trans/meth.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -116,9 +116,11 @@ pub fn trans_object_shim<'a, 'tcx>(ccx: &'a CrateContext<'a, 'tcx>,
116116
llfn
117117
}
118118

119-
/// Creates a returns a dynamic vtable for the given type and vtable origin.
119+
/// Creates a dynamic vtable for the given type and vtable origin.
120120
/// This is used only for objects.
121121
///
122+
/// The vtables are cached instead of created on every call.
123+
///
122124
/// The `trait_ref` encodes the erased self type. Hence if we are
123125
/// making an object `Foo<Trait>` from a value of type `Foo<T>`, then
124126
/// `trait_ref` would map `T:Trait`.

0 commit comments

Comments
 (0)