From ab4e44b06de53a0d322c4467c0f6bd5c4c7e9338 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Thu, 4 Oct 2012 17:01:57 -0700 Subject: [PATCH] Allow 'temporary' fields. --- src/FieldNames.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/FieldNames.h b/src/FieldNames.h index 784900c148..443ae50086 100644 --- a/src/FieldNames.h +++ b/src/FieldNames.h @@ -52,7 +52,11 @@ public: SField(int fc, SerializedTypeID tid, int fv, const char* fn) : fieldCode(fc), fieldType(tid), fieldValue(fv), fieldName(fn) - { codeToField[fc] = this; } + { codeToField[fieldCode] = this; } + + SField(SerializedTypeID tid, int fv, const char *fn, bool temporary) : + fieldCode(FIELD_CODE(tid, fv)), fieldType(tid), fieldValue(fv), fieldName(fn) + { if (!temporary) codeToField[fieldCode] = this; } SField(int fc) : fieldCode(fc), fieldType(STI_UNKNOWN), fieldValue(0) { ; }