Skip to content

Compiler plugin refactor #84

@JavierSegoviaCordoba

Description

@JavierSegoviaCordoba

buildMokokiMessage currently picks the data internally from stack traces. Instead, change the signature to provide that data in a lambda. Additionally, it can be a builder with more customization options.

As a first approach, it is only necessary to change buildHeader to find the IrCall, and extract from it the necessary data:

  • fileLink
  • fileName
  • className (or top-level)
  • methodName (or top-level, scripts?)
  • lineNumber
private fun buildHeader(tagToPrint: String, priority: Priority, vertical: String) =
    "$tagToPrint$priority.$fileLink $vertical " +
        "$fileName $vertical " +
        "$className $vertical " +
        "$methodName $vertical $lineNumber"

Metadata

Metadata

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions