|View Issue Details [ Jump to Notes ] ||[ Issue History ] [ Print ] |
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0031214||Open CASCADE||[OCCT] OCCT:Coding||public||2019-12-03 12:23||2019-12-03 12:23|
|Assigned To||kgv|| |
|Product Version|| |
|Target Version||[OCCT] 7.5.0*||Fixed in Version|| |
|Summary||0031214: Coding - minor improvements of opencascade::handle class template|
- A strange compilation error is issued when the template argument T of the opencascade::handle<T> class template is not derived from Standard_Transient. It would be nice to add a static assertion to the opencascade::handle<T> class template to make error message clearer.
- A strange behavior of the opencascade::handle<T> class template is observed with incomplete type T. It looks like that no compilation error is issued even when destructor of opencascade::handle<T>::~handle is called for incomplete T.
- It may be useful to add overloads that take an object of the type std::nullptr_t as an argument for constructor, assignment operator and reset() method of the opencascade::handle<T> class template using compilers that support C++11 and higher. nullptr may be used as a default argument for such overload of the reset() method.
- There is no operator ->* in the opencascade::handle<T> class template. It may be useful in operations with pointers to methods of the class T. Currently the following code
(aHandle.get()->*aPointerToMethod)(aMethodArguments...);should be written instead of
|Tags||No tags attached.|
|Test case number|