RESOLVED FIXED 16682
array_object.cpp needs a bath
https://bugs.webkit.org/show_bug.cgi?id=16682
Summary array_object.cpp needs a bath
Eric Seidel (no email)
Reported 2007-12-30 22:04:42 PST
array_object.cpp needs a bath Ok, so I was on a long flight, and figured I might poke my head around JSC a bit more. Sadly, it's hard to actually read any code in some of these old files. So I cleaned it up a little. Still not much more readable.
Attachments
Remove minInt, maxInt (3.37 KB, patch)
2007-12-30 22:07 PST, Eric Seidel (no email)
sam: review+
Apply wkstyle to array_object.cpp (18.64 KB, patch)
2007-12-30 22:07 PST, Eric Seidel (no email)
sam: review+
More small cleanup to array_object.cpp (19.03 KB, patch)
2007-12-30 22:07 PST, Eric Seidel (no email)
sam: review+
Eric Seidel (no email)
Comment 1 2007-12-30 22:07:46 PST
Created attachment 18201 [details] Remove minInt, maxInt Add a few planned renames for JavaScriptCore --- JavaScriptCore/kjs/array_object.cpp | 15 ++++++++------- JavaScriptCore/kjs/operations.cpp | 10 ---------- JavaScriptCore/kjs/operations.h | 3 --- WebKitTools/Scripts/do-webcore-rename | 4 ++++ 4 files changed, 12 insertions(+), 20 deletions(-)
Eric Seidel (no email)
Comment 2 2007-12-30 22:07:47 PST
Created attachment 18202 [details] Apply wkstyle to array_object.cpp JavaScriptCore/kjs/array_object.cpp | 250 +++++++++++++++++------------------ 1 files changed, 119 insertions(+), 131 deletions(-)
Eric Seidel (no email)
Comment 3 2007-12-30 22:07:49 PST
Created attachment 18203 [details] More small cleanup to array_object.cpp JavaScriptCore/kjs/array_object.cpp | 154 +++++++++++++++------------------- 1 files changed, 68 insertions(+), 86 deletions(-)
Sam Weinig
Comment 4 2007-12-30 22:24:24 PST
Comment on attachment 18201 [details] Remove minInt, maxInt This looks good, though I am not used to seeing the std::max/min with a template parameter. Are you sure that is kosher? Also, I think the change to do-webcore-rename should go in a separate commit. And you need CHANGELOGS.
Darin Adler
Comment 5 2007-12-30 22:27:00 PST
Comment on attachment 18202 [details] Apply wkstyle to array_object.cpp -namespace KJS { +namespace KJS +{ This may be the wkstyle, but it's not what the style guidelines say. - : ArrayInstance(objProto, 0) + : ArrayInstance(objProto, 0) Same here. It should be four spaces, not eight. if (curArg->isObject() && - curObj->inherits(&ArrayInstance::info)) { + curObj->inherits(&ArrayInstance::info)) { Why is this indented 10 spaces?
Darin Adler
Comment 6 2007-12-30 22:28:52 PST
Comment on attachment 18203 [details] More small cleanup to array_object.cpp + ((ArrayInstance* )thisObj)->sort(exec, sortFunction); + ((ArrayInstance* )thisObj)->sort(exec); Should delete the spaces here. Or use static_cast.
Sam Weinig
Comment 7 2007-12-30 22:36:21 PST
Comment on attachment 18202 [details] Apply wkstyle to array_object.cpp nice. r=me
David Kilzer (:ddkilzer)
Comment 8 2007-12-31 06:09:09 PST
(In reply to comment #4) > Also, I think the change to do-webcore-rename should go in a separate commit. r29043 The other changes landed in r29045, r29046, and r29047.
Note You need to log in before you can comment on or make changes to this bug.