From b095cbfba59a078e37e34d1a3f67b7b2a22c729b Mon Sep 17 00:00:00 2001 From: "rogerl%netscape.com" Date: Tue, 7 Nov 2000 01:09:45 +0000 Subject: [PATCH] Fixed warnings & bogus qualifier. git-svn-id: svn://10.0.0.236/trunk@82367 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/js/js2/js2.cpp | 2 +- mozilla/js/js2/numerics.cpp | 5 ++++- mozilla/js2/src/numerics.cpp | 5 ++++- mozilla/js2/tests/cpp/js2_shell.cpp | 2 +- 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/mozilla/js/js2/js2.cpp b/mozilla/js/js2/js2.cpp index 8a999d71cf0..d652608e6cb 100644 --- a/mozilla/js/js2/js2.cpp +++ b/mozilla/js/js2/js2.cpp @@ -173,7 +173,7 @@ static JSValue load(Context *cx, const JSValues &argv) static bool goGeorge = false; -static JSValue george(Context *cx, const JSValues &argv) +static JSValue george(Context *, const JSValues &) { goGeorge = !goGeorge; diff --git a/mozilla/js/js2/numerics.cpp b/mozilla/js/js2/numerics.cpp index f7a6088bf99..b70d319bbbe 100644 --- a/mozilla/js/js2/numerics.cpp +++ b/mozilla/js/js2/numerics.cpp @@ -227,11 +227,14 @@ InitNumerics::InitNumerics() word1(nan) = 0xFFFFFFFF; } +// had to move these here since they depend upon the values +// initialized above, and we can't guarantee order other than +// lexically in a single file. const JSValue JSTypes::kUndefinedValue; const JSValue JSTypes::kNaNValue = JSValue(nan); const JSValue JSTypes::kTrueValue = JSValue(true); const JSValue JSTypes::kFalseValue = JSValue(false); -const JSValue JSTypes::kNullValue = JSValue(JSValue::Tag::null_tag); +const JSValue JSTypes::kNullValue = JSValue(JSValue::null_tag); const JSValue JSTypes::kNegativeZero = JSValue(-0.0); const JSValue JSTypes::kPositiveZero = JSValue(0.0); const JSValue JSTypes::kNegativeInfinity = JSValue(negativeInfinity); diff --git a/mozilla/js2/src/numerics.cpp b/mozilla/js2/src/numerics.cpp index f7a6088bf99..b70d319bbbe 100644 --- a/mozilla/js2/src/numerics.cpp +++ b/mozilla/js2/src/numerics.cpp @@ -227,11 +227,14 @@ InitNumerics::InitNumerics() word1(nan) = 0xFFFFFFFF; } +// had to move these here since they depend upon the values +// initialized above, and we can't guarantee order other than +// lexically in a single file. const JSValue JSTypes::kUndefinedValue; const JSValue JSTypes::kNaNValue = JSValue(nan); const JSValue JSTypes::kTrueValue = JSValue(true); const JSValue JSTypes::kFalseValue = JSValue(false); -const JSValue JSTypes::kNullValue = JSValue(JSValue::Tag::null_tag); +const JSValue JSTypes::kNullValue = JSValue(JSValue::null_tag); const JSValue JSTypes::kNegativeZero = JSValue(-0.0); const JSValue JSTypes::kPositiveZero = JSValue(0.0); const JSValue JSTypes::kNegativeInfinity = JSValue(negativeInfinity); diff --git a/mozilla/js2/tests/cpp/js2_shell.cpp b/mozilla/js2/tests/cpp/js2_shell.cpp index 8a999d71cf0..d652608e6cb 100644 --- a/mozilla/js2/tests/cpp/js2_shell.cpp +++ b/mozilla/js2/tests/cpp/js2_shell.cpp @@ -173,7 +173,7 @@ static JSValue load(Context *cx, const JSValues &argv) static bool goGeorge = false; -static JSValue george(Context *cx, const JSValues &argv) +static JSValue george(Context *, const JSValues &) { goGeorge = !goGeorge;