Panda3D
 All Classes Functions Variables Enumerations
xFileParseData.cxx
00001 // Filename: xFileParseData.cxx
00002 // Created by:  drose (07Oct04)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) Carnegie Mellon University.  All rights reserved.
00008 //
00009 // All use of this software is subject to the terms of the revised BSD
00010 // license.  You should have received a copy of this license along
00011 // with this source code in a file named "LICENSE."
00012 //
00013 ////////////////////////////////////////////////////////////////////
00014 
00015 #include "xFileParseData.h"
00016 #include "xLexerDefs.h"
00017 
00018 
00019 ////////////////////////////////////////////////////////////////////
00020 //     Function: XFileParseData::Constructor
00021 //       Access: Public
00022 //  Description:
00023 ////////////////////////////////////////////////////////////////////
00024 XFileParseData::
00025 XFileParseData() :
00026   _parse_flags(0)
00027 {
00028   // Save the line number, column number, and line text in case we
00029   // detect an error later and want to report a meaningful message to
00030   // the user.
00031   _line_number = x_line_number;
00032   _col_number = x_col_number;
00033   _current_line = x_current_line;
00034 }
00035 
00036 ////////////////////////////////////////////////////////////////////
00037 //     Function: XFileParseData::yyerror
00038 //       Access: Public
00039 //  Description: Reports a parsing error message to the user, showing
00040 //               the line and column from which this object was
00041 //               originally parsed.
00042 ////////////////////////////////////////////////////////////////////
00043 void XFileParseData::
00044 yyerror(const string &message) const {
00045   xyyerror(message, _line_number, _col_number, _current_line);
00046 }
 All Classes Functions Variables Enumerations