// returns: (properties, first line not parsed) static Pair ctxParseProperties(L lines, int lineIndex) { SS properties = litorderedmap(); int i; for (i = lineIndex; i < l(lines); i++) { L tok2 = javaTok(lines.get(i)); if (l(tok2) == 1) continue; if (eqGet(tok2, 1, "[") && eqGet(tok2, 5, "]") && eqGet(tok2, 7, "=")) properties.put(tok2.get(3), unquoteCtx(trim(join(subList(tok2, 9))))); else break; } ret pair(properties, i); }