| 113 | * other (independence — the property the linearity gate rests on). */ |
| 114 | |
| 115 | static void cx_emit_java(FILE *f, int m, int j) { |
| 116 | fprintf(f, "package mod%d;\n\npublic class C%d {\n", m, j); |
| 117 | fprintf(f, " public int val%d(int x) {\n return x + %d;\n }\n", j, j); |
| 118 | if (j > 0) { |
| 119 | fprintf(f, " public int chain() {\n"); |
| 120 | fprintf(f, " C%d prev = new C%d();\n", j - 1, j - 1); |
| 121 | fprintf(f, " return prev.val%d(1) + val%d(2);\n }\n", j - 1, j); |
| 122 | } else { |
| 123 | fprintf(f, " public int chain() {\n return val0(2);\n }\n"); |
| 124 | } |
| 125 | fprintf(f, "}\n"); |
| 126 | } |
| 127 | |
| 128 | static void cx_emit_python(FILE *f, int m, int j) { |
| 129 | (void)m; |
nothing calls this directly
no outgoing calls
no test coverage detected