File tree 1 file changed +10
-1
lines changed
utbot-framework/src/main/kotlin/org/utbot/engine
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -2471,7 +2471,7 @@ class UtBotSymbolicEngine(
2471
2471
is JInterfaceInvokeExpr -> virtualAndInterfaceInvoke(invokeExpr.base, invokeExpr.methodRef, invokeExpr.args)
2472
2472
is JVirtualInvokeExpr -> virtualAndInterfaceInvoke(invokeExpr.base, invokeExpr.methodRef, invokeExpr.args)
2473
2473
is JSpecialInvokeExpr -> specialInvoke(invokeExpr)
2474
- is JDynamicInvokeExpr -> TODO ( " $ invokeExpr" )
2474
+ is JDynamicInvokeExpr -> dynamicInvoke( invokeExpr)
2475
2475
else -> error(" Unknown class ${invokeExpr::class } " )
2476
2476
}
2477
2477
@@ -2731,6 +2731,15 @@ class UtBotSymbolicEngine(
2731
2731
return commonInvokePart(invocation)
2732
2732
}
2733
2733
2734
+ private fun dynamicInvoke (invokeExpr : JDynamicInvokeExpr ): List <MethodResult > {
2735
+ workaround(HACK ) {
2736
+ // The engine does not yet support JDynamicInvokeExpr, so switch to concrete execution if we encounter it
2737
+ statesForConcreteExecution + = environment.state
2738
+ queuedSymbolicStateUpdates + = UtFalse .asHardConstraint()
2739
+ return emptyList()
2740
+ }
2741
+ }
2742
+
2734
2743
/* *
2735
2744
* Runs common invocation part for object wrapper or object instance.
2736
2745
*
You can’t perform that action at this time.
0 commit comments