View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0016965 | Open CASCADE | OCCT:Application Framework | public | 2007-09-14 17:24 | 2012-01-12 11:30 |
| Reporter | Assigned To | ||||
| Priority | normal | Severity | feature | ||
| Status | closed | Resolution | fixed | ||
| OS | All | ||||
| Fixed in Version | 6.2.1 | ||||
| Summary | 0016965: OCAF attributes should return strings by reference rather than by value | ||||
| Description | The improvement is simple: changing the signatures of a number of methods in TDataStd and TDataExt that return TCollection_AsciiString and TCollection_ExtendedString. When a method just copies the internal string to its return value, it is better to return a reference. For example: --> Previous version: TCollection_ExtendedString TDataStd_Name::Get() const {return myString;} --> New version: const TCollection_ExtendedString& TDataStd_Name::Get() const {return myString;} The benefit: the returned value is passed through a chain of nested calls, then the gain in CPU time may become important. | ||||
| Additional information and documentation updates | Documentation remark, added by AGV 2007-09-21 08:39:12: Improvements: Changing the signatures of a number of methods in TDataStd that return TCollection_AsciiString and TCollection_ExtendedString. Instead of copying the internal string to return value, it is better to return a reference. For example: --> Previous version: TCollection_ExtendedString TDataStd_Name::Get() const {return myString;} --> New version: const TCollection_ExtendedString& TDataStd_Name::Get() const {return myString;} The benefit: the returned value is passed through a chain of nested calls, then the gain in CPU time may become important. Modified entities: Package: TDataStd | ||||
| Tags | No tags attached. | ||||
| Test case number | |||||
| related to | 0016782 | closed | New OCAF attributes |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2007-09-14 17:30 |
|
OtherBugsDependingOnThis | => 16782 |
| 2007-09-21 09:42 | bugmaster | Assigned To | bugmaster => agv |
| 2007-09-21 09:42 | bugmaster | Status | new => assigned |
| 2007-09-21 10:39 |
|
Status | assigned => resolved |
| 2007-09-25 17:03 | bugmaster | Status | resolved => tested |
| 2007-10-25 18:32 | bugmaster | Status | tested => verified |
| 2009-06-23 19:09 | bugmaster | Status | verified => closed |
| 2009-06-23 19:09 | bugmaster | Resolution | @0@ => fixed |
| 2011-08-02 10:32 | bugmaster | Category | OCCT:OCAF => OCCT:Application Framework |
| 2012-01-12 11:30 |
|
Description Updated | |
| 2012-01-12 11:30 |
|
Additional Information Updated |