OverrideMapping

mill.define.OverrideMapping
@Scaladoc(value = "/**\n * Logic around mapping overridden tasks to `Segments` suffixes.\n *\n * If a task is overridden, only the final override is assigned the `foo`\n * segment, while the overridden tasks are assigned `foo.super/Bar` `foo.super/Qux`\n * etc.. The suffix is as short as possible for conciseness while still being distinct.\n *\n * To detect groups of overrides, we use the task names captured in the `Discover` macro.\n * This allows us to properly identify which `def` is the \"final\" one, which is difficult\n * to do by other means (e.g. JVM bytecode has synthetic forwarders that confuse things)\n */")

Logic around mapping overridden tasks to Segments suffixes.

If a task is overridden, only the final override is assigned the foo segment, while the overridden tasks are assigned foo.super/Bar foo.super/Qux etc.. The suffix is as short as possible for conciseness while still being distinct.

To detect groups of overrides, we use the task names captured in the Discover macro. This allows us to properly identify which def is the "final" one, which is difficult to do by other means (e.g. JVM bytecode has synthetic forwarders that confuse things)

Attributes

Source
OverrideMapping.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Type members

Classlikes

trait Wrapper

Attributes

Source
OverrideMapping.scala
Supertypes
class Object
trait Matchable
class Any
Known subtypes
trait Module
class BaseModule
object Kover
object KtfmtModule
object KtlintModule
object Giter8Module
object Dependency
object GenIdea
object PublishModule
trait MainModule
class RootModule
trait Module[T1]
trait CrossValue
trait Module2[T1, T2]
trait Module3[T1, T2, T3]
trait Module4[T1, T2, T3, T4]
trait Module5[T1, T2, T3, T4, T5]
class Cross[M]
trait TaskModule
trait JavaModule
trait KtfmtModule
trait KotlinModule
trait KotlinTests
trait KotestTests
trait DetektModule
trait KoverModule
trait BomModule
trait JlinkModule
trait MavenModule
trait SbtModule
trait ScalaModule
trait ScalaTests
trait ScalaJSTests
trait Tests
trait UnidocModule
trait TestModule
trait AndroidJUnit
trait Junit4
trait Junit5
trait Munit
trait ScalaTest
trait Specs2
trait TestNg
trait Utest
trait Weaver
trait ZioTest
trait RunModule
Show all

Value members

Concrete methods

def assignOverridenTaskSegments(overriddenEnclosings: Seq[String], taskMethodName: String, taskClassName: String): Segments

Attributes

Source
OverrideMapping.scala
def computeLinearization(cls: Class[_]): Seq[Class[_]]

Attributes

Source
OverrideMapping.scala
def computeSegments(enclosingValue: Wrapper, discover: Discover, lastSegmentStr: String, enclosingClassValue: Class[_]): Segments

Attributes

Source
OverrideMapping.scala