picoc's own diagnostics are terse and unpunctuated; match them.
| 35 | namespace { |
| 36 | // picoc's own diagnostics are terse and unpunctuated; match them. |
| 37 | const char* baseName(enum BaseType base) |
| 38 | { |
| 39 | switch (base) { |
| 40 | case TypeInt: |
| 41 | return "int"; |
| 42 | case TypePointer: |
| 43 | return "pointer"; |
| 44 | default: |
| 45 | return "value"; |
| 46 | } |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | void ScriptArgs::fail(const char* fmt, ...) const |