Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"Error:scalac: Error: object VolatileFloatRef does not have a member create" when using Scala 2.11.8 SDK

When I switch to Scala 2.11.8 SDK in IntelliJ, I get the following error during compile. Compiles fine when I use 2.10.6 SDK in IntelliJ with the same code.

Any ideas on how to fix this?

Error:scalac: Error: object VolatileFloatRef does not have a member create
scala.reflect.internal.FatalError: object VolatileFloatRef does not have a member create
    at scala.reflect.internal.Definitions$DefinitionsClass.scala$reflect$internal$Definitions$DefinitionsClass$$fatalMissingSymbol(Definitions.scala:1186)
    at scala.reflect.internal.Definitions$DefinitionsClass.getMember(Definitions.scala:1203)
    at scala.reflect.internal.Definitions$DefinitionsClass.getMemberMethod(Definitions.scala:1238)
    at scala.tools.nsc.transform.LambdaLift$$anonfun$scala$tools$nsc$transform$LambdaLift$$refCreateMethod$1.apply(LambdaLift.scala:41)
    at scala.tools.nsc.transform.LambdaLift$$anonfun$scala$tools$nsc$transform$LambdaLift$$refCreateMethod$1.apply(LambdaLift.scala:41)
    at scala.reflect.internal.util.Collections$$anonfun$mapFrom$1.apply(Collections.scala:182)
    at scala.reflect.internal.util.Collections$$anonfun$mapFrom$1.apply(Collections.scala:182)
    at scala.collection.immutable.List.map(List.scala:273)
    at scala.reflect.internal.util.Collections$class.mapFrom(Collections.scala:182)
    at scala.reflect.internal.SymbolTable.mapFrom(SymbolTable.scala:16)
    at scala.tools.nsc.transform.LambdaLift.scala$tools$nsc$transform$LambdaLift$$refCreateMethod$lzycompute(LambdaLift.scala:41)
    at scala.tools.nsc.transform.LambdaLift.scala$tools$nsc$transform$LambdaLift$$refCreateMethod(LambdaLift.scala:40)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.postTransform(LambdaLift.scala:489)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:544)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:56)
    at scala.reflect.api.Trees$Transformer$$anonfun$transformStats$1.apply(Trees.scala:2589)
    at scala.reflect.api.Trees$Transformer$$anonfun$transformStats$1.apply(Trees.scala:2587)
    at scala.collection.immutable.List.loop$1(List.scala:173)
    at scala.collection.immutable.List.mapConserve(List.scala:189)
    at scala.reflect.api.Trees$Transformer.transformStats(Trees.scala:2587)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformStats(LambdaLift.scala:562)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformStats(LambdaLift.scala:56)
    at scala.reflect.internal.Trees$class.itransform(Trees.scala:1366)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.api.Trees$Transformer.transform(Trees.scala:2555)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:44)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.scala$reflect$internal$Trees$UnderConstructionTransformer$$super$transform(ExplicitOuter.scala:219)
    at scala.reflect.internal.Trees$UnderConstructionTransformer$class.transform(Trees.scala:1705)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.transform(ExplicitOuter.scala:291)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.preTransform(LambdaLift.scala:536)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:544)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:56)
    at scala.reflect.internal.Trees$$anonfun$itransform$2.apply(Trees.scala:1363)
    at scala.reflect.internal.Trees$$anonfun$itransform$2.apply(Trees.scala:1361)
    at scala.reflect.api.Trees$Transformer.atOwner(Trees.scala:2600)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:30)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:25)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:17)
    at scala.reflect.internal.Trees$class.itransform(Trees.scala:1360)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.api.Trees$Transformer.transform(Trees.scala:2555)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:44)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.scala$reflect$internal$Trees$UnderConstructionTransformer$$super$transform(ExplicitOuter.scala:219)
    at scala.reflect.internal.Trees$UnderConstructionTransformer$class.transform(Trees.scala:1705)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.transform(ExplicitOuter.scala:291)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.preTransform(LambdaLift.scala:536)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:544)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:56)
    at scala.reflect.api.Trees$Transformer$$anonfun$transformStats$1.apply(Trees.scala:2589)
    at scala.reflect.api.Trees$Transformer$$anonfun$transformStats$1.apply(Trees.scala:2587)
    at scala.collection.immutable.List.loop$1(List.scala:173)
    at scala.collection.immutable.List.mapConserve(List.scala:189)
    at scala.reflect.api.Trees$Transformer.transformStats(Trees.scala:2587)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformStats(LambdaLift.scala:562)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformStats(LambdaLift.scala:56)
    at scala.reflect.internal.Trees$class.itransform(Trees.scala:1404)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.api.Trees$Transformer.transform(Trees.scala:2555)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.scala$tools$nsc$transform$TypingTransformers$TypingTransformer$$super$transform(TypingTransformers.scala:40)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$transform$1.apply(TypingTransformers.scala:40)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$transform$1.apply(TypingTransformers.scala:40)
    at scala.reflect.api.Trees$Transformer.atOwner(Trees.scala:2600)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:30)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:40)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.scala$reflect$internal$Trees$UnderConstructionTransformer$$super$transform(ExplicitOuter.scala:219)
    at scala.reflect.internal.Trees$UnderConstructionTransformer$class.transform(Trees.scala:1705)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.transform(ExplicitOuter.scala:291)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.preTransform(LambdaLift.scala:536)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:544)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:56)
    at scala.reflect.api.Trees$Transformer.transformTemplate(Trees.scala:2563)
    at scala.reflect.internal.Trees$$anonfun$itransform$4.apply(Trees.scala:1408)
    at scala.reflect.internal.Trees$$anonfun$itransform$4.apply(Trees.scala:1407)
    at scala.reflect.api.Trees$Transformer.atOwner(Trees.scala:2600)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:30)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:25)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:17)
    at scala.reflect.internal.Trees$class.itransform(Trees.scala:1406)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.api.Trees$Transformer.transform(Trees.scala:2555)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:44)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.scala$reflect$internal$Trees$UnderConstructionTransformer$$super$transform(ExplicitOuter.scala:219)
    at scala.reflect.internal.Trees$UnderConstructionTransformer$class.transform(Trees.scala:1705)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.transform(ExplicitOuter.scala:291)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.preTransform(LambdaLift.scala:536)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:544)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:56)
    at scala.reflect.api.Trees$Transformer$$anonfun$transformStats$1.apply(Trees.scala:2589)
    at scala.reflect.api.Trees$Transformer$$anonfun$transformStats$1.apply(Trees.scala:2587)
    at scala.collection.immutable.List.loop$1(List.scala:173)
    at scala.collection.immutable.List.mapConserve(List.scala:189)
    at scala.reflect.api.Trees$Transformer.transformStats(Trees.scala:2587)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformStats(LambdaLift.scala:562)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformStats(LambdaLift.scala:56)
    at scala.reflect.internal.Trees$$anonfun$itransform$7.apply(Trees.scala:1426)
    at scala.reflect.internal.Trees$$anonfun$itransform$7.apply(Trees.scala:1426)
    at scala.reflect.api.Trees$Transformer.atOwner(Trees.scala:2600)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:30)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:25)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:17)
    at scala.reflect.internal.Trees$class.itransform(Trees.scala:1425)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.internal.SymbolTable.itransform(SymbolTable.scala:16)
    at scala.reflect.api.Trees$Transformer.transform(Trees.scala:2555)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.scala$tools$nsc$transform$TypingTransformers$TypingTransformer$$super$transform(TypingTransformers.scala:40)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$transform$2.apply(TypingTransformers.scala:42)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$transform$2.apply(TypingTransformers.scala:42)
    at scala.reflect.api.Trees$Transformer.atOwner(Trees.scala:2600)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:30)
    at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:42)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.scala$reflect$internal$Trees$UnderConstructionTransformer$$super$transform(ExplicitOuter.scala:219)
    at scala.reflect.internal.Trees$UnderConstructionTransformer$class.transform(Trees.scala:1705)
    at scala.tools.nsc.transform.ExplicitOuter$OuterPathTransformer.transform(ExplicitOuter.scala:291)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.preTransform(LambdaLift.scala:536)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:544)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transform(LambdaLift.scala:56)
    at scala.tools.nsc.ast.Trees$Transformer.transformUnit(Trees.scala:147)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.scala$tools$nsc$transform$LambdaLift$LambdaLifter$$super$transformUnit(LambdaLift.scala:568)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter$$anonfun$transformUnit$1.apply(LambdaLift.scala:568)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter$$anonfun$transformUnit$1.apply(LambdaLift.scala:568)
    at scala.reflect.internal.SymbolTable.enteringPhase(SymbolTable.scala:235)
    at scala.reflect.internal.SymbolTable.exitingPhase(SymbolTable.scala:256)
    at scala.tools.nsc.transform.LambdaLift$LambdaLifter.transformUnit(LambdaLift.scala:567)
    at scala.tools.nsc.transform.Transform$Phase.apply(Transform.scala:30)
    at scala.tools.nsc.Global$GlobalPhase$$anonfun$applyPhase$1.apply$mcV$sp(Global.scala:440)
    at scala.tools.nsc.Global$GlobalPhase.withCurrentUnit(Global.scala:431)
    at scala.tools.nsc.Global$GlobalPhase.applyPhase(Global.scala:440)
    at scala.tools.nsc.Global$GlobalPhase$$anonfun$run$1.apply(Global.scala:398)
    at scala.tools.nsc.Global$GlobalPhase$$anonfun$run$1.apply(Global.scala:398)
    at scala.collection.Iterator$class.foreach(Iterator.scala:893)
    at scala.collection.AbstractIterator.foreach(Iterator.scala:1336)
    at scala.tools.nsc.Global$GlobalPhase.run(Global.scala:398)
    at scala.tools.nsc.Global$Run.compileUnitsInternal(Global.scala:1501)
    at scala.tools.nsc.Global$Run.compileUnits(Global.scala:1486)
    at scala.tools.nsc.Global$Run.compileSources(Global.scala:1481)
    at scala.tools.nsc.Global$Run.compile(Global.scala:1582)
    at xsbt.CachedCompiler0.run(CompilerInterface.scala:115)
    at xsbt.CachedCompiler0.run(CompilerInterface.scala:94)
    at xsbt.CompilerInterface.run(CompilerInterface.scala:22)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at sbt.compiler.AnalyzingCompiler.call(AnalyzingCompiler.scala:101)
    at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:47)
    at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:41)
    at org.jetbrains.jps.incremental.scala.local.IdeaIncrementalCompiler.compile(IdeaIncrementalCompiler.scala:29)
    at org.jetbrains.jps.incremental.scala.local.LocalServer.compile(LocalServer.scala:26)
    at org.jetbrains.jps.incremental.scala.remote.Main$.make(Main.scala:67)
    at org.jetbrains.jps.incremental.scala.remote.Main$.nailMain(Main.scala:24)
    at org.jetbrains.jps.incremental.scala.remote.Main.nailMain(Main.scala)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at com.martiansoftware.nailgun.NGSession.run(NGSession.java:319)
like image 723
Saqib Ali Avatar asked Feb 07 '23 04:02

Saqib Ali


1 Answers

Got the same issue, and I confirm that it comes from a Scala version mismatch. I just want to add that I had to do (in my case) in IntelliJ :

right click on your project -> maven -> reimport

Worked fine after that

like image 133
ImbaBalboa Avatar answered Feb 11 '23 19:02

ImbaBalboa