diff options
| author | KyleMiles <krm504@nyu.edu> | 2018-07-16 15:56:28 -0400 |
|---|---|---|
| committer | KyleMiles <krm504@nyu.edu> | 2018-07-16 15:56:28 -0400 |
| commit | f9d7cc83105d6cbfe03409c6eddbc039b0d9839c (patch) | |
| tree | 73ad748088574ad5b97c19453c01db82eb7eb78c /python/generator.cpp | |
| parent | 2c7f443ce0b3d92ea44acb440c1891344eacc6d4 (diff) | |
Fix format of strings in python/log.py
Diffstat (limited to 'python/generator.cpp')
| -rw-r--r-- | python/generator.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/python/generator.cpp b/python/generator.cpp index afc77254..39e45aea 100644 --- a/python/generator.cpp +++ b/python/generator.cpp @@ -391,6 +391,16 @@ int main(int argc, char* argv[]) } fprintf(out, "\t]\n"); } + else + { + // As of writing this, only BNLog's have variable instruction lengths, but in an attempt not to break in the future: + if (funcName.compare(0, 6, "_BNLog") == 0) + { + fprintf(out, "def %s(*args):\n", name.c_str()); + fprintf(out, "\treturn %s(*[cstr(arg) for arg in args])\n\n", funcName.c_str()); + continue; + } + } if (stringResult) { |
