View Issue Details

IDProjectCategoryView StatusLast Update
0025620Open CASCADEOCCT:Codingpublic2019-10-25 14:49
ReporteraznAssigned Toabv 
PrioritynormalSeverityminor 
Status closedResolutionunable to reproduce 
Product Version6.7.0 
Summary0025620: CAST analysis: Avoid public or missing copy assignment operator in abstract classes
DescriptionThe copy assignment operator lets you create a new object from an existing object through initialization. A copy assignment operator of a class A is a non-static, non-template member function that has one of the following forms:

    * A::operator=(A)
    * A::operator=(A&)
    * A::operator=(const A&)
    * A::operator=(volatile A&)
    * A::operator=(const volatile A&)

If you do not declare a copy assignment operator for a class A, the compiler will implicitly declare one for you which will be inline public.

Assignment operators using pointers are also taken into account:

    * A::operator=(A*)
    * A::operator=(const A*)
    * A::operator=(volatile A*)
    * A::operator=(const volatile A*)

By ensuring that the copy assignment operator is protected, it can only be, and should only be, called by the assignment operator of the derived class.
Additional information
and documentation updates
It is necessary to move assignment operator in protected section in Standard_Transient class.

More details: CAST report, issue 7926
TagsNo tags attached.
Test case number

Relationships

related to 0024023 closedabv Revamp the OCCT Handle 

Activities

abv

2019-10-25 14:49

manager   ~0088595

Standard_Transient is not an abstract class (and it was not abstract in traceable history), thus the issue is irrelevant to that class. There is no indication for possible occurrence of such issue in other classes, thus closing the issue.

Issue History

Date Modified Username Field Change
2014-12-16 17:55 azn New Issue
2014-12-16 17:55 azn Assigned To => azn
2015-04-21 06:08 abv Target Version 6.9.0 => 7.1.0
2016-11-01 06:41 abv Target Version 7.1.0 => 7.2.0
2017-07-20 12:26 kgv Assigned To azn =>
2017-07-20 12:26 kgv Target Version 7.2.0 => 7.4.0
2019-07-10 19:27 abv Target Version 7.4.0 => 7.5.0
2019-10-25 14:33 abv Relationship added related to 0024023
2019-10-25 14:49 abv Note Added: 0088595
2019-10-25 14:49 abv Assigned To => abv
2019-10-25 14:49 abv Status new => closed
2019-10-25 14:49 abv Resolution open => unable to reproduce
2019-10-25 14:49 abv Target Version 7.5.0 =>