Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
46 lines (31 sloc) 864 Bytes
- //inside[_ <: javax.swing.JComponent].
// BOF : insidePackage("scala.lang").
- activer remplacements dans un scope
replacing(..., ..., ...) {
}
- activer ou desactiver
- ajouter dependence des rewrites dans sbt
- plugin sbt pour generer remplacement pour sa librairie et les publier (replacements.properties...)
- Refactoring : hyper utile pour migrer ˆ nouvelle version code
-> ...
- object MesExemples extends Rock {
def enabled(compilerContext) = {
if (compC.scalaVersion < ...)
false
}
def context1(....) =
replace(patt, rep)
def context1(...) =
warn(msg) { patt }
def context1(...) =
fail(msg) { patt }
def context1(...) =
when(patt)(id1, id2...) {
case ...: Tree =>
replacement(rep)
case ... =>
error(rep)
case ... =>
warning(rep)
}
}