-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Crash when compiling ekrich/sconfig #7175
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
Comments
Thanks for the bug report, I think there is a higher chance of having someone looking into it if it can be minimized into a self contained example. |
I will try and produce a minimization. |
Here is reproducer that produces an error which may be the underlying cause of the crash. This obviously compiles in object foo {
def main(args: Array[String]): Unit = println("Dotty")
import java.net.URL
import java.util.List
trait ConfigOrigin {
def description: String
def filename: String
def url: URL
def resource: String
def lineNumber: Int
def comments: List[String]
def withComments(comments: List[String]): ConfigOrigin
def withLineNumber(lineNumber: Int): ConfigOrigin
}
trait ConfigValue extends ConfigMergeable {
def origin: ConfigOrigin
//def valueType: ConfigValueType
def unwrapped: AnyRef
def render: String
//def render(options: ConfigRenderOptions): String
override def withFallback(other: ConfigMergeable): ConfigValue
//def atPath(path: String): Config
//def atKey(key: String): Config
def withOrigin(origin: ConfigOrigin): ConfigValue
}
trait ConfigMergeable {
def withFallback(other: ConfigMergeable): ConfigMergeable
}
trait MergeableValue extends ConfigMergeable {
def toFallbackValue(): ConfigValue
}
// no impl
final class SimpleConfigOrigin extends ConfigOrigin {
def comments: java.util.List[String] = ???
def description: String = ???
def filename: String = ???
def lineNumber: Int = ???
def resource: String = ???
def url: java.net.URL = ???
def withComments(comments: java.util.List[String]): foo.ConfigOrigin = ???
def withLineNumber(lineNumber: Int): foo.ConfigOrigin = ???
}
abstract class AbstractConfigValue (val _origin: ConfigOrigin)
extends ConfigValue
with MergeableValue {
override def origin(): SimpleConfigOrigin =
this._origin.asInstanceOf[SimpleConfigOrigin]
}
} |
I removed the parens on |
One other point. Adding |
This is the commit that errors since I have moved past that commit. |
After #7430, I get
Once I change |
Thank-you! |
minimized code
When preparing
sconfig
to compile with Dotty. There is currently another issue as well: #7174https://github.com/ekrich/sconfig/tree/topic/dotty
Using the branch above:
Notes from Gitter - September 5, 2019 5:47 PM
Portions removed.
Stack trace
The text was updated successfully, but these errors were encountered: