Bug 87038

Summary: Web Inspector: $_ for last calculated result
Product: WebKit Reporter: homakov <homakov>
Component: Web Inspector (Deprecated)Assignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: apavlov, bweinstein, homakov, joepeck, keishi, loislo, paulirish, pfeldman, pmuellr, rik, timothy, yurys
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   

Description homakov 2012-05-21 12:49:15 PDT
It would be nice to have smth like __ or $_ variable available in console - it is _ in Ruby.
It will save some time and also suits since we already have $0-4 for latest DOM elements.
Also implementation is only 1 LOC.
Comment 1 Pavel Feldman 2012-05-21 13:37:06 PDT
Sounds good to me. Do you have a patch?
Comment 2 homakov 2012-05-21 13:42:11 PDT
not yet. Just need more "+1" - and it will be committed!
Comment 3 Pavel Feldman 2012-05-21 13:50:22 PDT
(In reply to comment #2)
> not yet. Just need more "+1" - and it will be committed!

You don't need more "+1", feel free to attach the patch and I'll review it. Note that this change would need a test. See LayoutTests/inspector/console/command-line-api.html and other command-line tests for more info.
Comment 4 homakov 2012-05-25 01:09:09 PDT
(In reply to comment #3)
> (In reply to comment #2)
> > not yet. Just need more "+1" - and it will be committed!
> 
> You don't need more "+1", feel free to attach the patch and I'll review it. Note that this change would need a test. See LayoutTests/inspector/console/command-line-api.html and other command-line tests for more info.

Great. Just having some issues with contexts - learning how webinspector works with $0-4 and doesn't pollute current window JS namespace.
Comment 5 Paul Irish 2012-08-07 11:22:36 PDT

*** This bug has been marked as a duplicate of bug 93377 ***