Thanks Cody. That was a good explanation!
Mohit Jaggi
Founder,
Data Orchard LLC
www.dataorchardllc.com
> On Aug 31, 2016, at 7:32 AM, Cody Koeninger wrote:
>
> http://blog.originate.com/blog/2014/02/27/types-inside-types-in-scala/
>
> On Wed, Aug 31, 2016 at 2:19 AM, Sean Owen wrote:
>> We
http://blog.originate.com/blog/2014/02/27/types-inside-types-in-scala/
On Wed, Aug 31, 2016 at 2:19 AM, Sean Owen wrote:
> Weird, I recompiled Spark with a similar change to Model and it seemed
> to work but maybe I missed a step in there.
>
> On Wed, Aug 31, 2016 at 6:33 AM, Mohit Jaggi wrote:
Weird, I recompiled Spark with a similar change to Model and it seemed
to work but maybe I missed a step in there.
On Wed, Aug 31, 2016 at 6:33 AM, Mohit Jaggi wrote:
> I think I figured it out. There is indeed "something deeper in Scala” :-)
>
> abstract class A {
> def a: this.type
> }
>
> cl
I think I figured it out. There is indeed "something deeper in Scala” :-)
abstract class A {
def a: this.type
}
class AA(i: Int) extends A {
def a = this
}
the above works ok. But if you return anything other than “this”, you will get
a compile error.
abstract class A {
def a: this.type
}
thanks Sean. I am cross posting on dev to see why the code was written that
way. Perhaps, this.type doesn’t do what is needed.
Mohit Jaggi
Founder,
Data Orchard LLC
www.dataorchardllc.com
On Aug 30, 2016, at 2:08 PM, Sean Owen wrote:
I think it's imitating, for example, how Enum is delcared
thanks Sean. I am cross posting on dev to see why the code was written that
way. Perhaps, this.type doesn’t do what is needed.
Mohit Jaggi
Founder,
Data Orchard LLC
www.dataorchardllc.com
> On Aug 30, 2016, at 2:08 PM, Sean Owen wrote:
>
> I think it's imitating, for example, how Enum is de
I think it's imitating, for example, how Enum is delcared in Java:
abstract class Enum>
this is done so that Enum can refer to the actual type of the derived
enum class when declaring things like public final int compareTo(E o)
to implement Comparable. The type is redundant in a sense, because
yo