From 52305657b6eea5d9a0dea17f72f8865281ebbccc Mon Sep 17 00:00:00 2001 From: Nick Fitzgerald Date: Tue, 20 Jun 2017 16:36:10 -0700 Subject: Add a comment about template instantiation parentage --- src/ir/context.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ir/context.rs b/src/ir/context.rs index a53eba14..eb0fd98a 100644 --- a/src/ir/context.rs +++ b/src/ir/context.rs @@ -1038,6 +1038,11 @@ impl<'ctx> BindgenContext<'ctx> { /// Incomplete bar; /// }; /// ``` + /// + /// Finally, template instantiations are always children of the current + /// module. They use their template's definition for their name, so the + /// parent is only useful for ensuring that their layout tests get + /// codegen'd. fn instantiate_template(&mut self, with_id: ItemId, template: ItemId, -- cgit v1.2.3