final object Rewrites

Handles rewriting of Scala2 files to Dotty

Constructors

Members

private case class Patch
private final object Patch
private class PatchedFiles
private class Patches
def patch ( source: SourceFile , pos: Position , replacement: String ) ( implicit ctx: Context ) : Unit

If -rewrite is set, record a patch that replaces the range given by pos in source by replacement

If -rewrite is set, record a patch that replaces the range given by pos in source by replacement

def patch ( pos: Position , replacement: String ) ( implicit ctx: Context ) : Unit

Patch position in ctx.compilationUnit.source.

Patch position in ctx.compilationUnit.source.

def writeBack ( ) ( implicit ctx: Context ) : Unit

If -rewrite is set, apply all patches and overwrite patched source files.

If -rewrite is set, apply all patches and overwrite patched source files.