RE: [PHP-DEV] open_muscat; Fatal error: Class declarations may not be nested in /var/www/html/xapian/test.php on line 3

From: Date: Mon, 11 Feb 2002 16:28:02 +0000
Subject: RE: [PHP-DEV] open_muscat; Fatal error: Class declarations may not be nested in /var/www/html/xapian/test.php on line 3
Groups: php.dev 
Request: Send a blank email to php-dev+get-79941@lists.php.net to get a copy of this message
OK, swig wasn't writing out: CG(Active_class_entry) = NULL; after it finished. I'll take it up with seig folk. Sam > -----Original Message----- > From: Sam Liddicott [mailto:sam.liddicott@ananova.com] > Sent: 11 February 2002 16:12 > To: php-dev@lists.php.net > Subject: [PHP-DEV] open_muscat; Fatal error: Class > declarations may not > be nested in /var/www/html/xapian/test.php on line 3 > > > I've got a first revision of the php module for open_muscat > (now called > xapian). > I used swig to generate this. > Swig works by declaring a class in the C code and then having > a load of > methods of this class to do the work, and then some php > classes which shadow > the C classes but use the new methods of the secret single > class to do the > actual work. > > Like: > ... > $this->_c_ptr=xapianc::new_OmQieryTerm("hi",0,0); > ... > return xapianc::OmQuery_get_description($this->_c_ptr); > > and all that kind of thing; > > The problem is merely loading the xapian module gives this > error if even the > simplest class is declared (with no include files at all) > Fatal error: Class declarations may not be nested in > /var/www/html/xapian/test.php on line 3 > > The same tiny class definitions work fine if the xapian > module does not > load. > > I can't find decent docs on internal class declarations but > obviously it has > not been "closed"; how might I go about doing this? > > Sam > > > > > -- > PHP Development Mailing List <http://www.php.net/> > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.dev (#79941) next »