Apache OpenOffice (AOO) Bugzilla – Full Text Issue Listing |
Summary: | IRIX: svx: The initial value of a reference to a non-const must be an lvalue. | ||
---|---|---|---|
Product: | porting | Reporter: | nickb |
Component: | code | Assignee: | sander_traveling |
Status: | CLOSED WONT_FIX | QA Contact: | issues@porting <issues> |
Severity: | Trivial | ||
Priority: | P3 | CC: | issues |
Version: | OOo 1.1 RC | ||
Target Milestone: | AOO PleaseHelp | ||
Hardware: | SGI | ||
OS: | IRIX | ||
Issue Type: | DEFECT | Latest Confirmation in: | --- |
Developer Difficulty: | --- | ||
Issue Depends on: | |||
Issue Blocks: | 809 |
Description
nickb
2003-08-04 00:16:40 UTC
The source looks like this: INT32 SvxSearchDialog::GetTransliterationFlags() const { INT32 &rFlags = (INT32) nTransliterationFlags; if (!aMatchCaseCB.IsChecked()) rFlags |= TransliterationModules_IGNORE_CASE; else rFlags &= ~TransliterationModules_IGNORE_CASE; if ( !aJapMatchFullHalfWidthCB.IsChecked()) rFlags |= TransliterationModules_IGNORE_WIDTH; else rFlags &= ~TransliterationModules_IGNORE_WIDTH; return nTransliterationFlags; } I think (and I could be wrong) that this is bad C++. The function is marked const, yet it changes nTransliterationFlags. I have changed rFlags so its not a refence, and changed the function to return rFlags. If someone was relying on nTransliterationFlags changing after a call to this function, then this change will break that. However, it is not compliant C++ the way it is. set target milestone to 1.1.1 reassigned. retarget to 2.0 per issue 106845 sb removed the partial irix port, so this doesn't make sense in isolation anymore closing |