alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

Scala example source code file (t2556_3.check)

This example Scala source code file (t2556_3.check) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - Scala tags/keywords

a, a, b, c, c, changes, list, map, map, note, parentchanged, predef, predef, scalaobject,scalaobject

The Scala t2556_3.check source code

builder > A.scala B.scala C.scala
compiling Set(A.scala, B.scala, C.scala)
Changes: Map()
builder > A.scala
compiling Set(A.scala)
Changes: Map(class A -> List(), class B -> List(Changed(Class(B))[List((A,java.lang.Object), (ScalaObject,ScalaObject))]))
invalidate C.scala because parents have changed [Changed(Class(B))[List((A,java.lang.Object), (ScalaObject,ScalaObject))]]
invalidate B.scala because it references invalid (no longer inherited) definition [ParentChanged(Class(C))]
compiling Set(B.scala, C.scala)
B.scala:3: error: type mismatch;
 found   : C
 required: ?{val x: ?}
Note that implicit conversions are not applicable because they are ambiguous:
 both method any2Ensuring in object Predef of type [A](x: A)Ensuring[A]
 and method any2ArrowAssoc in object Predef of type [A](x: A)ArrowAssoc[A]
 are possible conversion functions from C to ?{val x: ?}
    println( (new C).x )
              ^

Other Scala examples (source code examples)

Here is a short list of links related to this Scala t2556_3.check source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.