summaryrefslogtreecommitdiff
path: root/src/parser.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/parser.cc')
-rw-r--r--src/parser.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/parser.cc b/src/parser.cc
index 78f8df95..264508cd 100644
--- a/src/parser.cc
+++ b/src/parser.cc
@@ -869,7 +869,8 @@ void BaseParser::contextVarDef( const InputLoc &loc, ObjectField *objField )
object->rootScope->insertField( objField->name, objField );
}
-void BaseParser::contextHead( const InputLoc &loc, const String &data )
+void BaseParser::contextHead( const InputLoc &loc, const String &data,
+ ObjectDef::Type objectType )
{
/* Make the new namespace. */
Namespace *nspace = createNamespace( loc, data );
@@ -880,7 +881,7 @@ void BaseParser::contextHead( const InputLoc &loc, const String &data )
ContextDef *contextDef = new ContextDef( data, context, nspace );
nspace->contextDefList.append( contextDef );
- context->objectDef = ObjectDef::cons( ObjectDef::UserType,
+ context->objectDef = ObjectDef::cons( objectType,
data, pd->nextObjectId++ );
}