On 17/06/14 06:44, H. S. Teoh via Digitalmars-d wrote:
String mixins? Auto-completion? I dunno, that sounds like a stretch to
me. How would an IDE handle autocompletion for things like like:
string generateCode() {
string code = "int x=";
if (solveFermatsLastTheorem()) {
code ~= "1";
} else {
code ~= "2";
}
code ~= ";";
return code;
}
int func() {
mixin(generateCode());
}
That would require semantic analysis. Basically evaluate the string
mixin and to autocomplete on the resulted code.
--
/Jacob Carlborg