WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
54001
Web Inspector: use call frame column to determine execution line in source frame
https://bugs.webkit.org/show_bug.cgi?id=54001
Summary
Web Inspector: use call frame column to determine execution line in source frame
Pavel Podivilov
Reported
2011-02-08 07:35:36 PST
Web Inspector: use call frame column to determine execution line in source frame
Attachments
Patch.
(19.46 KB, patch)
2011-02-08 07:39 PST
,
Pavel Podivilov
no flags
Details
Formatted Diff
Diff
Patch.
(19.47 KB, patch)
2011-02-09 02:59 PST
,
Pavel Podivilov
yurys
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Pavel Podivilov
Comment 1
2011-02-08 07:39:56 PST
Created
attachment 81634
[details]
Patch.
Yury Semikhatsky
Comment 2
2011-02-09 00:00:13 PST
Comment on
attachment 81634
[details]
Patch. View in context:
https://bugs.webkit.org/attachment.cgi?id=81634&action=review
> Source/WebCore/bindings/js/JavaScriptCallFrame.h:58 > + int line() const { return m_textPosition.m_line.zeroBasedInt(); }
What's the reason for switching from 1-based to 0-based here?
> Source/WebCore/bindings/js/ScriptDebugServer.cpp:446 > + TextPosition0 textPosition(WTF::ZeroBasedNumber::fromZeroBasedInt(lineNumber - 1), WTF::ZeroBasedNumber::base());
Should be WTF::OneBasedNumber::fromOneBasedInt(lineNumber).convertToZeroBased()
Pavel Podivilov
Comment 3
2011-02-09 02:59:39 PST
Created
attachment 81782
[details]
Patch.
Pavel Podivilov
Comment 4
2011-02-09 03:05:31 PST
(In reply to
comment #2
)
> (From update of
attachment 81634
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=81634&action=review
> > > Source/WebCore/bindings/js/JavaScriptCallFrame.h:58 > > + int line() const { return m_textPosition.m_line.zeroBasedInt(); } > > What's the reason for switching from 1-based to 0-based here?
Using 0-based lines in protocol is preferable because most of the scripts panel code is using 0-based lines, and maintaining +1/-1 conversions all over the code is painful.
> > > Source/WebCore/bindings/js/ScriptDebugServer.cpp:446 > > + TextPosition0 textPosition(WTF::ZeroBasedNumber::fromZeroBasedInt(lineNumber - 1), WTF::ZeroBasedNumber::base()); > > Should be WTF::OneBasedNumber::fromOneBasedInt(lineNumber).convertToZeroBased()
Done.
Pavel Podivilov
Comment 5
2011-02-14 08:40:40 PST
Committed
r78482
: <
http://trac.webkit.org/changeset/78482
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug