Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Organization of the leon library #304

Open
NicolasRouquette opened this issue Mar 25, 2017 · 0 comments
Open

Organization of the leon library #304

NicolasRouquette opened this issue Mar 25, 2017 · 0 comments

Comments

@NicolasRouquette
Copy link

I like to compile my scala code with these flags:


scalacOptions ++= Seq(
  "-deprecation",
  "-encoding", "UTF-8",     // yes, this is 2 args
  "-feature",
  "-language:existentials",
  "-language:higherKinds",
  "-language:implicitConversions",
  "-unchecked",
  "-Xfatal-warnings",
  "-Xlint",
  "-Yno-adapted-args",
  "-Ywarn-dead-code",       // N.B. doesn't work well with the ??? hole
  "-Ywarn-numeric-widen",
  "-Ywarn-value-discard",
  "-Xfuture",
  "-Ywarn-unused-import",   // 2.11 only
  "-Yno-imports"            // no automatic imports at all; all symbols must be imported explicitly
)

The león library defines many objects & classes in a package object.
This results in a warning with scalac that with the above flags becomes an error.

Is it possible to refactor the library; e.g., instead of:

file: library/leon/annotation/package.scala:


package leon

import scala.annotation.StaticAnnotation

package object annotation {
  @ignore
  class library    extends StaticAnnotation
...

Each of the objects/classes would be defined in a corresponding compilation unit, e.g.:

library would be defined in library/leon/annotation/library.scala

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant