scaladget icon indicating copy to clipboard operation
scaladget copied to clipboard

scaladjet import conflict with string scala predef

Open romainreuillon opened this issue 6 years ago • 0 comments

This code should be sufficient to produce the error:

import scaladget.tools._
"test".take(1)
[error]  found   : path.type (with underlying type String)
[error]  required: ?{def takeRight(x$1: ? >: Int(10)): ?}
[error] Note that implicit conversions are not applicable because they are ambiguous:
[error]  both method augmentString in object Predef of type (x: String)scala.collection.immutable.StringOps
[error]  and method stringToModifierSeq in trait Stylesheet of type (classString: String)scaladget.tools.package.ModifierSeq
[error]  are possible conversion functions from path.type to ?{def takeRight(x$1: ? >: Int(10)): ?}
[error]   def shorten(path: String): String = if (path.length > 10) s"...${path.takeRight(10)}" else path
[error]                    
```                                                ^

romainreuillon avatar Apr 03 '18 06:04 romainreuillon