Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Move function isInsideStaticInitializer to ExecutionState.kt
  • Loading branch information
sergeypospelov committed Jul 8, 2022
commit b3137a9854eb4bbf0e07619bbf7cd37eb609e59e
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,9 @@ data class ExecutionState(
val isThrowException: Boolean
get() = (lastEdge?.decisionNum ?: 0) < CALL_DECISION_NUM

val isInsideStaticInitializer
get() = executionStack.any { it.method.isStaticInitializer }

fun createExceptionState(
exception: SymbolicFailure,
update: SymbolicStateUpdate
Expand Down
4 changes: 0 additions & 4 deletions utbot-framework/src/main/kotlin/org/utbot/engine/Traverser.kt
Original file line number Diff line number Diff line change
Expand Up @@ -389,10 +389,6 @@ class Traverser(
private val featureProcessor: FeatureProcessor? =
if (enableFeatureProcess) EngineAnalyticsContext.featureProcessorFactory(globalGraph) else null

private val insideStaticInitializer
get() = environment.state.executionStack.any { it.method.isStaticInitializer }


private val objectCounter = AtomicInteger(TypeRegistry.objectCounterInitialValue)
private fun findNewAddr(insideStaticInitializer: Boolean): UtAddrExpression {
val newAddr = objectCounter.getAndIncrement()
Expand Down