summaryrefslogtreecommitdiff
path: root/rust/src/types.rs
diff options
context:
space:
mode:
authorGlenn Smith <glenn@vector35.com>2023-03-21 17:29:10 -0400
committerGlenn Smith <glenn@vector35.com>2023-03-22 15:37:59 -0400
commit3098871098535217641117052875831268461095 (patch)
treee5a680674ed639c9e666a76271466f05f0f96f93 /rust/src/types.rs
parentb5ae0b5262c5337bc9a949d176883550c924fb90 (diff)
DebugInfo: Make datavar types have confidence
Diffstat (limited to 'rust/src/types.rs')
-rw-r--r--rust/src/types.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/rust/src/types.rs b/rust/src/types.rs
index 6bd85d0e..11934ceb 100644
--- a/rust/src/types.rs
+++ b/rust/src/types.rs
@@ -2179,6 +2179,15 @@ impl DataVariableAndName<String> {
}
impl<S: BnStrCompatible> DataVariableAndName<S> {
+ pub fn new(address: u64, t: Conf<Ref<Type>>, auto_discovered: bool, name: S) -> Self {
+ Self {
+ address,
+ t,
+ auto_discovered,
+ name,
+ }
+ }
+
pub fn type_with_confidence(&self) -> Conf<Ref<Type>> {
Conf::new(self.t.contents.clone(), self.t.confidence)
}