So I just tried to use libmesh_cast_ptr for the first time.... and I'm  
not  really sure about the interface.  Here's what I'm doing

PetscMatrix<T> * pmatrix = libmesh_cast_ptr<PetscMatrix<T>*,  
SparseMatrix<T> >(this->_matrix);

What I don't like is how you have to pass Tnew as a pointer type (ie  
with a *) but Told you pass _without_ a *.  I don't really care either  
way... but it feels like both arguments should be the same.   
Personally, since the name of the function has _ptr in it.... it seems  
that we should just drop the need to pass pointer types.... ie:

PetscMatrix<T> * pmatrix = libmesh_cast_ptr<PetscMatrix<T>,  
SparseMatrix<T> >(this->_matrix);

What do you guys think?  Am I thinking about this wrong?  I'm sure Roy  
had a good reason for doing it this way....

Derek

------------------------------------------------------------------------------
Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
software. With Adobe AIR, Ajax developers can use existing skills and code to
build responsive, highly engaging applications that combine the power of local
resources and data with the reach of the web. Download the Adobe AIR SDK and
Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com
_______________________________________________
Libmesh-devel mailing list
Libmesh-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libmesh-devel

Reply via email to