summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCameron McCormack <cam@mcc.id.au>2019-10-04 16:17:13 +1000
committerEmilio Cobos Álvarez <emilio@crisal.io>2019-10-08 01:40:07 +0200
commit807fa1e959781721f202fb0d8e2f3f8fc955f1e9 (patch)
treeb5fe9d056771a853fc9eec93c7eac9b844adf622
parenta7fb8bff61025fa26a2ab080270796afd9ffdf42 (diff)
Rename Item::canonical_name_cache for consistency.
-rw-r--r--src/ir/item.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ir/item.rs b/src/ir/item.rs
index cc94d789..78edcf2c 100644
--- a/src/ir/item.rs
+++ b/src/ir/item.rs
@@ -397,7 +397,7 @@ pub struct Item {
///
/// This is a fairly used operation during codegen so this makes bindgen
/// considerably faster in those cases.
- canonical_name_cache: LazyCell<String>,
+ canonical_name: LazyCell<String>,
/// The path to use for whitelisting and other name-based checks, as
/// returned by `path_for_whitelisting`, lazily constructed.
@@ -438,7 +438,7 @@ impl Item {
id: id,
local_id: LazyCell::new(),
next_child_local_id: Cell::new(1),
- canonical_name_cache: LazyCell::new(),
+ canonical_name: LazyCell::new(),
path_for_whitelisting: LazyCell::new(),
parent_id: parent_id,
comment: comment,
@@ -1834,7 +1834,7 @@ impl ItemCanonicalName for Item {
ctx.in_codegen_phase(),
"You're not supposed to call this yet"
);
- self.canonical_name_cache
+ self.canonical_name
.borrow_with(|| {
let in_namespace = ctx.options().enable_cxx_namespaces ||
ctx.options().disable_name_namespacing;