scalac Questions
3
Solved
How can I find all of the flags for the latest scalac version? After googling for hours I have found only outdated docs. (for example, they don't even mention "-feature" flag).
Is there any way to...
Jorgensen asked 3/9, 2013 at 20:58
1
Currently, the dotty compiler released its first Release Candidate and will be released in the next few months.
I updated the IntelliJ scala plugin to EarlyAccess to make it working with Scala 3.0,...
Albert asked 18/2, 2021 at 12:20
5
I want to be able to use -Xfatal-warnings and -Ywarn-unused-import, the problem is that the compiler is triggering an error on the file which contains the play routes for my application:
[error] /...
Theobald asked 24/5, 2016 at 12:4
1
Solved
I have been stuck on this issue for a week and don't seem to be getting anywhere. I am trying to copy some methods and fields from one class to another.
I have two phases that are involved in this....
Planospore asked 21/10, 2021 at 5:21
2
So I have a jar file that contains scala as the source code and I have lost the original code. Is there a way to convert the class files in the jar to scala functions and classes instead of the jav...
Salesperson asked 2/3, 2016 at 2:38
1
Solved
Assuming that A class called 'summoner' was defined, that is capable of summoning implicit views from the scope:
case class Summoner[R]() {
def summon[T](v: T)(implicit ev: T => R): R = ev(v)...
1
Solved
I have a custom class, A, and I have defined some operations within the class as follows:
def +(that: A) = ...
def -(that: A) = ...
def *(that: A) = ...
def +(that: Double) = ...
def -(that: Doub...
Paola asked 14/4, 2019 at 23:11
5
I'm trying to use the java jcommander library from Scala. The java JCommander class has multiple constructors:
public JCommander(Object object)
public JCommander(Object object, ResourceBundle ...
4
Solved
I want to sharpen my picture of the phases of scala compilation. I know that certain things have to happen in the compiler, but don't really know the order in which they happen and how the order sh...
Ruvalcaba asked 24/12, 2010 at 18:58
4
Solved
Running w/ a simple SBT project w/ Java 7 (details below) and invoking sbt run at the command line (no IntelliJ or anything)
source
import scala.tools.nsc.{ Global, Settings }
object Playground ...
Mendelson asked 14/1, 2015 at 1:6
1
Solved
Consider the following class:
package test
class Test {
def main(args: Array[String]): Unit = {
val i: Int = 0
println(i)
}
}
The bytecode of main is:
public main([Ljava/lang/String;)V
// ...
2
Solved
I'm new to Scala, and I've never written or compiled a program in it before. I'm trying to simply run the following Hello World example, which I have saved in a file name scalaApp.scala
object sca...
2
Solved
I get an error there were 15 feature warning(s); re-run with -feature for details :
$ /usr/local/sbt/bin/sbt
[info] Loading project definition from /home/alex/Documents/projects/my_app123/project...
0
I've got a project that isn't a crazy number of lines of code, but its compilation time is really long on a clean compile. I have the feeling there are some hotspots, but I don't know how to find t...
1
I am trying to call sbt assembly from the command line passing it a scalac compiler flag to elides (elide-below 1).
I have managed to get the flag working in the build.sbt by adding this line to t...
2
Solved
I have written some implicit code as shown below, and I am wondering why the i2d function implicit conversation isn't invoked.
object Test {
implicit def i2d(x: Int): Double = {
println("foo")
...
Sadonia asked 16/8, 2016 at 4:20
0
I was reading this question and saw:
scalac includes an 8-bit simulator of a fully armed and operational battle station, viewable using the magic key combination CTRL-ALT-F12 during the GenICode...
1
I am trying to add a library dependency through an sbt plugin. The dependency should be added to each sub-project per its binary scala version, so I iterate through each subproject.
private def i...
2
Solved
Does the scala compiler optimize for memory usage by removing refs to vals used only once within a block?
Imagine an object holding in aggregate some huge data - reaching a size where cloning dat...
Biogeography asked 22/11, 2015 at 9:25
1
Solved
When I'm doing sbt compile -feature on my Scala project I get a mysterious warnings:
The `-` command is deprecated in favor of `onFailure` and will be removed in 0.14.0
I have no clue what that ...
1
I am in the process of upgrading a large project to 2.10.4 to 2.11.4. I have gotten a compiler crash, is there anyway to display the name of source file that is causing the crash? I am able to get ...
3
I would like to extract from a given Scala project, the call graph of all methods which are part of the project's own source.
As I understand, the presentation compiler doesn't enable that, and it...
Rossner asked 22/4, 2015 at 0:15
1
Solved
When decompiling Scala files to Java code, one often comes across classes that are annotated with the ScalaSignatures. These seem to only have one annotation value, a somewhat encoded String. Why d...
Incommunicado asked 25/3, 2015 at 21:49
1
Solved
WartRemover is a scalac plugin. Typically it is configured via an sbt plugin.
I'd like to be able to run WartRemover on my sbt project as a separate configuration or task without affecting the usu...
2
Solved
I recently noticed Scala compiler warnings that maven was generating that looked like this:
[WARNING] warning: there were 4 deprecation warning(s); re-run with -deprecation for details
[WARNING] ...
Spermiogenesis asked 18/3, 2014 at 23:46
1 Next >
© 2022 - 2024 — McMap. All rights reserved.