tmp< T >
Hi FOAMers
Can any one tell me "tmp< T >" class is for what? It seems it is "A class for managing temporary objects." but can any one explain for me what is difference between const GeometricField< Type, fvsPatchField, surfaceMesh > and const tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > Any help will be appreciated Best regards Ata |
|
Thanks
Hi Anton Kidess
Thank you very much Best regards Ata |
difference between tmp<T> and &T
Hi Anton Kidess
So, would you please tell me what is difference between tmp<T> and passing a reference (&T)? Thank you very much Best regards Ata |
tmp is used for returning *local variables* without copying. You can't pass a reference because the data it points to is going out of scope. There's an article on the wiki here:
http://openfoamwiki.net/index.php/OpenFOAM_guide/tmp |
Thanks
Hi David
Thank you very much Best regards Ata |
All times are GMT -4. The time now is 03:59. |