Skip to content

Instantly share code, notes, and snippets.

@joseoliv
Created June 24, 2019 07:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joseoliv/f364ba67c0d07bdf711eb4cfebe4ff84 to your computer and use it in GitHub Desktop.
Save joseoliv/f364ba67c0d07bdf711eb4cfebe4ff84 to your computer and use it in GitHub Desktop.
afti_dsa_test(MetSig,UMS,Ret).myan
var String funcName;
func afti_beforeMethodCodeList {
return [ [. MetSig, "fp = \"c\";".], [. UMS, "unaryReturn = Ret;" .] ];
}
func afti_codeToAdd {
var java.lang.String ssi = "func succ: Int n -> Int";
var String s = ssi;
return [. "func succ: Int n -> Int = n + 1;", s .];
}
func dsa_codeToAdd {
var String s = compiler getEnv getCurrentProgramUnit getName;;
return "nowExist = 5; \n" ++ "currentProgramUnitName = \"" ++ s ++ "\";\n";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment