From: Jay Freeman (saurik) Date: Mon, 19 Oct 2009 01:53:13 +0000 (+0000) Subject: Added cyrver to make clean, fixed GC protection for CYJS*, implemented array comprehe... X-Git-Tag: v0.9.432~318 X-Git-Url: https://git.saurik.com/cycript.git/commitdiff_plain/75b0a45730c047dc8bf77060f4fade2488e073fa?ds=sidebyside Added cyrver to make clean, fixed GC protection for CYJS*, implemented array comprehensions and for each, added a -c flag for pure-compiler mode, and added (driver.pool_) tags on some memory allocations in the grammar. --- diff --git a/Console.cpp b/Console.cpp index fdfc054..b3702ca 100644 --- a/Console.cpp +++ b/Console.cpp @@ -218,6 +218,7 @@ static void Console(int socket) { else { CYDriver driver(""); cy::parser parser(driver); + //parser.set_debug_level(1); driver.data_ = command.c_str(); driver.size_ = command.size(); @@ -301,14 +302,19 @@ static void *Map(const char *path, size_t *psize) { int main(int argc, char *argv[]) { bool tty(isatty(STDIN_FILENO)); pid_t pid(_not(pid_t)); + bool compile(false); - for (;;) switch (getopt(argc, argv, "p:")) { + for (;;) switch (getopt(argc, argv, "cp:")) { case -1: goto getopt; case '?': - fprintf(stderr, "usage: cycript [-p ] [