deleting static const breaks solaris native build

VERIFIED FIXED

Status

()

P3
normal
VERIFIED FIXED
19 years ago
19 years ago

People

(Reporter: tomi.leppikangas, Assigned: buster)

Tracking

Trunk
Sun
Solaris
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: 10/15: Requested verification by reporter)

(Reporter)

Description

19 years ago
Kipps changes to
mozilla/layout/html/style/src/nsCSSKeywords.cpp and
mozilla/layout/html/style/src/nsCSSProps.cpp
breaks solaris native compiler with error:
Error: Non-const function nsCString::__SLIP.DELETER__B() called for const
object.

When downgraded to versions nsCSSKeywords.cpp/3.10 and nsCSSProps.cpp/3.17
solaris compiles ok.

Comment 1

19 years ago
Obviously I can't reproduce this on linux, so I need *alot* more information to
be able to do anything about it. Thanks!
(Reporter)

Comment 2

19 years ago
I am not c++ expert, but can you delete const objects? kNullStr is defined
as static const, and then deleted, i guess that its the problem. (my summary
line is all wrong) I get it compile in solaris by removing const keyword,
here is a patch:


Index: nsCSSKeywords.cpp
===================================================================
RCS file: /cvsroot/mozilla/layout/html/style/src/nsCSSKeywords.cpp,v
retrieving revision 3.11
diff -u -r3.11 nsCSSKeywords.cpp
--- nsCSSKeywords.cpp   1999/10/05 14:51:55     3.11
+++ nsCSSKeywords.cpp   1999/10/13 22:14:01
@@ -62,7 +62,7 @@
 static KeywordNode* gKeywordArray;
 static nsAVLTree*   gKeywordTree;
 static KeywordComparitor* gComparitor;
-static const nsCString* kNullStr;
+static nsCString* kNullStr;

 void
 nsCSSKeywords::AddRefTable(void)
Index: nsCSSProps.cpp
===================================================================
RCS file: /cvsroot/mozilla/layout/html/style/src/nsCSSProps.cpp,v
retrieving revision 3.19
diff -u -r3.19 nsCSSProps.cpp
--- nsCSSProps.cpp      1999/10/12 00:30:54     3.19
+++ nsCSSProps.cpp      1999/10/13 22:14:03
@@ -67,7 +67,7 @@
 static PropertyNode*  gPropertyArray;
 static nsAVLTree*     gPropertyTree;
 static PropertyComparitor*  gComparitor;
-static const nsCString* kNullStr;
+static nsCString* kNullStr;

 void
 nsCSSProps::AddRefTable(void)

Comment 3

19 years ago
Thanks for the patch :-) I'll be landing the fix today as soon as the tree
opens...

Updated

19 years ago
Status: NEW → RESOLVED
Last Resolved: 19 years ago
Resolution: --- → FIXED

Comment 4

19 years ago
I just landed your patches. Nice catch, and thanks!

Updated

19 years ago
Whiteboard: 10/15: Requested verification by reporter

Comment 5

19 years ago
Tomi.Leppikangas@oulu.fi: If you agree that bug is fixed, please mark it
verified as I have insufficient information to do so. Thanks.
(Reporter)

Updated

19 years ago
Status: RESOLVED → VERIFIED
Summary: static constructors breaks solaris native build → deleting static const breaks solaris native build
(Reporter)

Comment 6

19 years ago
Yes this fixes compile problem, marking as verified. Also changed summary
line to more specific.
You need to log in before you can comment on or make changes to this bug.