因此intellij编译器在编译时破坏了。根据我的理解,索引越界是一个运行时错误。怎么能在编译时发生?以下是我正在尝试为ScalaTest编译的内容:
class ConfigurationTest extends FlatSpec{
behavior of "Configuration"
it should "have a full configuration" in {
val dashboard = ConfigurationService.getDashboardConfig("1")
val dTest = write(dashboard)
val mockFormat =//Really long Json Object as a string >6000 lines
val testObj = read[JDashboard](mockFormat)
assert(dTest.equals(mockFormat))
}
implicit var formats = org.json4s.native.Serialization.formats(NoTypeHints)
}
由于它是在intellij之外构建的,我假设intellij的内部jvm在某处有限制,但为什么会发生这种情况呢?