From be0d40a87ae580a7016616573bd42e6c996a4345 Mon Sep 17 00:00:00 2001 From: Alexey Menshutin Date: Mon, 24 Jul 2023 16:19:53 +0300 Subject: [PATCH] Review fixes --- usvm-core/src/main/kotlin/org/usvm/CallStack.kt | 4 +++- .../kotlin/org/usvm/ps/ExceptionPropagationPathSelector.kt | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/usvm-core/src/main/kotlin/org/usvm/CallStack.kt b/usvm-core/src/main/kotlin/org/usvm/CallStack.kt index e72b0eb27..ca615309c 100644 --- a/usvm-core/src/main/kotlin/org/usvm/CallStack.kt +++ b/usvm-core/src/main/kotlin/org/usvm/CallStack.kt @@ -41,7 +41,9 @@ class UCallStack private constructor( .zipWithNext { first, second -> UStackTraceFrame(first.method, second.returnSite!!) } .toMutableList() - return stacktrace + UStackTraceFrame(stack.last().method, currentInstruction) + stacktrace += UStackTraceFrame(stack.last().method, currentInstruction) + + return stacktrace } override fun toString(): String { diff --git a/usvm-core/src/main/kotlin/org/usvm/ps/ExceptionPropagationPathSelector.kt b/usvm-core/src/main/kotlin/org/usvm/ps/ExceptionPropagationPathSelector.kt index 305d90961..f29107b14 100644 --- a/usvm-core/src/main/kotlin/org/usvm/ps/ExceptionPropagationPathSelector.kt +++ b/usvm-core/src/main/kotlin/org/usvm/ps/ExceptionPropagationPathSelector.kt @@ -15,13 +15,13 @@ class ExceptionPropagationPathSelector>( // to determine whether some state is already in the queue or not // without extra time consumption. // We use only keys from this map. - private val exceptionalStates = IdentityHashMap() + private val exceptionalStates = IdentityHashMap() // An identity map of the states that were added in the internal selector. // That means that these states present not only in the internal queue, but in // the queue of the selector, and we have to process them as well. // We use only keys from this map. - private val statesInSelector = IdentityHashMap() + private val statesInSelector = IdentityHashMap() override fun isEmpty(): Boolean = exceptionalStates.isEmpty() && selector.isEmpty()