From 3451a844d37e09a7529a751ba7919eee642f963c Mon Sep 17 00:00:00 2001 From: Alexander Kuechler Date: Mon, 23 Oct 2023 16:52:24 +0200 Subject: [PATCH] More properties --- .../aisec/cpg/graph/declarations/ValueDeclaration.kt | 2 ++ .../aisec/cpg/graph/statements/expressions/Reference.kt | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/declarations/ValueDeclaration.kt b/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/declarations/ValueDeclaration.kt index 0835ebd7b1..df0044e888 100644 --- a/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/declarations/ValueDeclaration.kt +++ b/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/declarations/ValueDeclaration.kt @@ -61,6 +61,8 @@ abstract class ValueDeclaration : Declaration(), HasType { } } + var aliases = mutableSetOf() + override var assignedTypes: Set = mutableSetOf() set(value) { if (field == value) { diff --git a/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/statements/expressions/Reference.kt b/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/statements/expressions/Reference.kt index 57ce5a3cba..891a7dfb45 100644 --- a/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/statements/expressions/Reference.kt +++ b/cpg-core/src/main/kotlin/de/fraunhofer/aisec/cpg/graph/statements/expressions/Reference.kt @@ -72,7 +72,9 @@ open class Reference : Expression(), HasType.TypeObserver { value.registerTypeObserver(this) } } - // set the access + + var aliases = mutableSetOf() + /** * Is this reference used for writing data instead of just reading it? Determines dataflow * direction