Mailinglist Archive: opensuse-buildservice (233 mails)

< Previous Next >
[opensuse-buildservice] 'assert’ was not declared in this scope
  • From: Richard Bos <ml@xxxxxxxxxx>
  • Date: Sat, 12 May 2007 14:49:09 +0200
  • Message-id: <200705121449.10342.ml@xxxxxxxxxx>
Does soneone know, what can be done to prevent or solve the error below:
xml.cpp: In member function ‘int xml::push_parser_context::parse(char*, int)’:
xml.cpp:283: error: ‘assert’ was not declared in this scope
make[2]: *** [xml.o] Fout 1


The file to be compiled
xml.cpp:
.........
extern "C"
{
#include <libxml/parser.h>
#include <libxml/tree.h>
#include <libxml/relaxng.h>
}

namespace xml
{
.....................
280     if (context_ == 0)
281     {
282       context_ = xmlCreatePushParserCtxt(handler_, data_, buffer, size, 
file    name_);
283       assert(context_ != 0);
284       return 0;
285     }
286     else
287       return xmlParseChunk(context_, buffer, size, size == 0);
288   }

Commenting out 'assert' results in a succesful compile.


-- 
TIA,

Richard Bos
We are borrowing the world of our children,
It is not inherited from our parents.
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-buildservice+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups