Branch: Tag:

1998-10-22

1998-10-22 09:12:26 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

new feature: make optimize

Rev: lib/master.pike.in:1.35
Rev: src/Makefile.in:1.121
Rev: src/dumpmaster.pike:1.1
Rev: src/dumpmodule.pike:1.1
Rev: src/pike-module.in:1.2

1: + #define UNDEFINED (([])[0])    -  + void handle_error(mixed err) + { +  werror("%O\n",err); + } + program compile_file(string file) + { +  return compile(cpp(_static_modules.files()->Fd(file,"r")->read(),file)); + } +  + class Codec + { +  string nameof(string x) +  { +  if(mixed tmp=search(all_constants(),x)) return tmp; +  return UNDEFINED; +  } + } + void _main(string *argv, string *env) + { +  program p=compile_file(argv[-1]); +  string s=encode_value(p, Codec()); +  _static_modules.files()->Fd(argv[-1] + ".o","wct")->write(s); +  exit(0); + }   Newline at end of file added.