Bug 161513

Summary: jsc: provide printErr()
Product: WebKit Reporter: JF Bastien <jfbastien>
Component: JavaScriptCoreAssignee: JF Bastien <jfbastien>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, keith_miller, mark.lam, msaboff, saam
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
patch none

Description JF Bastien 2016-09-01 15:30:53 PDT
SpiderMonkey provides print / printErr to print to stdout / stderr.
Node has console.log / console.error.

jsc has print, the emscripten shell would like to have printErr.
Comment 1 JF Bastien 2016-09-01 15:33:32 PDT
Created attachment 287691 [details]
patch
Comment 2 JF Bastien 2016-09-01 15:35:01 PDT
I'm not sure where / if to test this. I did the following locally:

$ ./current/bin/jsc 
>>> print([1,2,3])
1,2,3
undefined
>>> printErr([3,4,5])
3,4,5
undefined
>>> ^Dundefined

$ ./current/bin/jsc 1> /dev/null
print("hello")
printErr("hi!")
hi!
Comment 3 Mark Lam 2016-09-01 15:40:48 PDT
Comment on attachment 287691 [details]
patch

r=me
Comment 4 WebKit Commit Bot 2016-09-01 18:03:25 PDT
Comment on attachment 287691 [details]
patch

Clearing flags on attachment: 287691

Committed r205328: <http://trac.webkit.org/changeset/205328>
Comment 5 WebKit Commit Bot 2016-09-01 18:03:32 PDT
All reviewed patches have been landed.  Closing bug.
Comment 6 Keith Miller 2016-09-01 18:21:37 PDT
Committed r205330: <http://trac.webkit.org/changeset/205330>
Comment 7 Mark Lam 2016-09-01 19:16:01 PDT
(In reply to comment #6)
> Committed r205330: <http://trac.webkit.org/changeset/205330>

I think Keith meant this comment for https://bugs.webkit.org/show_bug.cgi?id=161471.  Due to a ChangeLog mixup, he added it here.