WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
190926
Add rudimentary `console` support to jsc for use when inspecting jsc
https://bugs.webkit.org/show_bug.cgi?id=190926
Summary
Add rudimentary `console` support to jsc for use when inspecting jsc
Joseph Pecoraro
Reported
2018-10-25 16:14:47 PDT
Add rudimentary `console` support to jsc for use when inspecting jsc Currently: $ jsc >>> console.log("test") Exception: TypeError: undefined is not an object (evaluating 'console.log') Expected something like: $ jsc --enable-console >>> console.log('test') CONSOLE LOG test undefined It is rudimentary, just using our currently Log to System Console support, not node.js like `console` support. But when a JSContext Inspector is attached (jsc --remote-debug) this allows for full `console` support).
Attachments
[PATCH] Proposed Fix
(2.54 KB, patch)
2018-10-25 16:16 PDT
,
Joseph Pecoraro
dino
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Joseph Pecoraro
Comment 1
2018-10-25 16:16:18 PDT
Created
attachment 353123
[details]
[PATCH] Proposed Fix
Dean Jackson
Comment 2
2018-10-26 13:12:33 PDT
My comment to Joe was that we shouldn't prefix output with "CONSOLE LOG" because it makes it difficult to use jsc as a generation tool. He disagreed, suggesting that node is the right solution for that.
Joseph Pecoraro
Comment 3
2018-10-26 13:31:46 PDT
(In reply to Dean Jackson from
comment #2
)
> My comment to Joe was that we shouldn't prefix output with "CONSOLE LOG" > because it makes it difficult to use jsc as a generation tool. > > He disagreed, suggesting that node is the right solution for that.
I do agree we could improve on console.log's formatting. But enabling it like this is simple and makes it work completely in remote inspection, which was my goal with this change.
Keith Miller
Comment 4
2018-11-07 10:25:20 PST
Comment on
attachment 353123
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=353123&action=review
> Source/JavaScriptCore/jsc.cpp:2669 > + if (!strcmp(arg, "--enable-console")) {
Should we also enable this by default if you pass "--remote-debug"?
Dean Jackson
Comment 5
2018-11-07 10:46:06 PST
Comment on
attachment 353123
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=353123&action=review
>> Source/JavaScriptCore/jsc.cpp:2669 >> + if (!strcmp(arg, "--enable-console")) { > > Should we also enable this by default if you pass "--remote-debug"?
Yes! Good idea.
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