Smart Pointer Usage with derviable class?

[email protected]
Newsgroups gmane.comp.lang.lua.bind.user
Message-ID <a801af462ae73b31513a9ee8889498da.squirrel@webmail.uranium-anchor.com>
I have a class that I want to derive from in lua, with a smart-pointer
like container but I'm getting template compilation errors and I can't
figure out what's missing. Actor has a private constructor, but Actor_w
and ActorId do not.

class ActorId {
 // blah blah
// other stuff here too but this is the end result of *id
 Actor *operator *() const { return a; }
 // blah blah
};

void initActor() {
// blah blah
	module(L) [
	 class_<Actor, Actor_w, ActorId>("Actor")
         .def(constructor<>()) // this line causes failure, see below
// blah blah
	];
}

If I remove the .def(constructor<>()) line it compiles fine, so I'm not
sure what I'm missing here.

Errors are here:

http://pastebin.org/172694

This is with VS2010 Pro edition, boost 1.42.1, and luabind 0.9.


------------------------------------------------------------------------------
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.