pike.git / src / post_modules / GL / gen.pike

version» Context lines:

pike.git/src/post_modules/GL/gen.pike:326:       if(sizeof(got))    res += "\n"+got+"\n";       switch(r234)    {    case 0:    if(polya<0)    res += (vret?" res=":" ")+fu+"("+(args*",")+");\n";    else -  res += " switch("+args[polya]+".type) {\n"+ +  res += " switch(TYPEOF("+args[polya]+")) {\n"+    Array.map(argt[polya]/"|", lambda(string t)    {    array(string) a = copy_value(args);    a[polya] += ".u";    switch(t) {    case "int":    a[polya]+=".integer"; break;    case "float":    a[polya]+=".float_number"; break;    }
pike.git/src/post_modules/GL/gen.pike:496:    res += " add_integer_constant(\""+co+"\", "+    (string)val+", ID_FINAL);\n";    }    res += " post_init();\n";    res += "}\n";    return res;   }      void main(int argc, array(string) argv)   { -  array(string) f = Stdio.File("stdin")->read()/"@@"; +  array(string) f = Stdio.File((argc>1?argv[1]:"stdin"))->read()/"@@";    write(({    "#line 1 \"auto.c.in\"\n",    f[0],    sprintf("\n#line %d \"auto.c (generated by %s)\"\n",    String.count (f[0], "\n") + 4, __FILE__),    gen(),    sprintf("\n#line %d \"auto.c.in\"\n", sizeof(f[0]/"\n")),    @f[1..]})*"");   }