Closed sfc-gh-bli closed 2 months ago
Looks like only a few action functions needs offset. I feel like it is a bit fragile since change of the way calling action function could break the offset. Do you think we are going to make changes on the way we call those action functions in the future?
val index = if (isScala) 4 else 5 + javaOffSet
val fileName = stacks(index).getFileName
val lineNumber = stacks(index).getLineNumber
Default stack index of Scala API is 4, and the Java One is 5. Offset is related the default Java API index(5), default value of offset is 0.
In future if the change of action
function impacts those indices, we only need change the default value (4 and 5) from the action
function. I will not impact the offset.