Warning: session_start(): open(/var/lib/php/sessions/sess_c7i16qpgddll1b5rq1fp8hbd1p, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
// adds default constructor to classes with "persistable" modifier
svoid tok_persistableClasses(LS tok) {
int i;
while((i = jfind(tok, "persistable", tokCondition {
for (int j = i+1; isIdentifier(_get(tok, j)); j += 2)
if (eqGet(tok, j, "class"))
true;
false;
})) >= 0) {
int iClass = indexOf(tok, "class", i);
int idx = indexOf(tok, iClass, "{");
L contents = subList(tok, idx+1, j);
LS contentsWithoutCurly = replaceCurlyBracedWith(tok_combineCurlyBrackets_keep(cloneList(contents)), "");
bool hasDefaultConstructor = jcontains(contentsWithoutCurly, "*()");
if (!hasDefaultConstructor)
tokAppend_reTok(idx, "\n *() {}");
clearTokens_reTok(i, i+2); // drop persistable keyword
}
}