1879 "/ is a block of the steppedContext, we must really |
1879 "/ is a block of the steppedContext, we must really |
1880 "/ do a single step. Otherwise, stepping through a |
1880 "/ do a single step. Otherwise, stepping through a |
1881 "/ do:-loop would be very difficult. |
1881 "/ do:-loop would be very difficult. |
1882 |
1882 |
1883 (where receiver isBlock |
1883 (where receiver isBlock |
1884 and:[where receiver home == steppedContext]) |
1884 and:[(where receiver isKindOf:Block) |
|
1885 and:[where receiver home == steppedContext]]) |
1885 ifTrue:[ |
1886 ifTrue:[ |
1886 anyStepBlocks := true. |
1887 anyStepBlocks := true. |
1887 ] ifFalse:[ |
1888 ] ifFalse:[ |
1888 where args do:[:arg | |
1889 where args do:[:arg | |
1889 (arg isBlock |
1890 (arg isBlock |
1890 and:[arg home == steppedContext]) |
1891 and:[(arg isKindOf:Block) |
|
1892 and:[arg home == steppedContext]]) |
1891 ifTrue:[ |
1893 ifTrue:[ |
1892 anyStepBlocks := true. |
1894 anyStepBlocks := true. |
1893 ] |
1895 ] |
1894 ] |
1896 ] |
1895 ]. |
1897 ]. |
2287 ! |
2289 ! |
2288 |
2290 |
2289 browseImplementorsOf |
2291 browseImplementorsOf |
2290 "open a browser on the implementors of some selector" |
2292 "open a browser on the implementors of some selector" |
2291 |
2293 |
2292 |initial selector| |
2294 |initial selector sel| |
2293 |
2295 |
2294 initial := codeView selection |
2296 (sel := codeView selection) notNil ifTrue:[ |
2295 ifNil:[selectedContext isNil |
2297 initial := BrowserView extractSelectorFrom:sel |
|
2298 ]. |
|
2299 initial isNil ifTrue:[ |
|
2300 initial := selectedContext isNil |
2296 ifTrue:[nil] |
2301 ifTrue:[nil] |
2297 ifFalse:[selectedContext selector]]. |
2302 ifFalse:[selectedContext selector]. |
|
2303 ]. |
2298 selector := Dialog |
2304 selector := Dialog |
2299 request:'Selector to browse implementors of:' |
2305 request:'Selector to browse implementors of:' |
2300 initialAnswer:initial. |
2306 initialAnswer:initial. |
2301 selector size == 0 ifFalse:[ |
2307 selector size == 0 ifFalse:[ |
2302 SystemBrowser browseImplementorsOf:selector asSymbol. |
2308 SystemBrowser browseImplementorsOf:selector asSymbol. |
2303 ] |
2309 ] |
|
2310 |
|
2311 "Modified: / 6.2.2000 / 01:05:14 / cg" |
2304 ! |
2312 ! |
2305 |
2313 |
2306 browseSenders |
2314 browseSenders |
2307 "open a browser on the senders of the selected methods selector" |
2315 "open a browser on the senders of the selected methods selector" |
2308 |
2316 |
2313 ! |
2321 ! |
2314 |
2322 |
2315 browseSendersOf |
2323 browseSendersOf |
2316 "open a browser on the senders of some selector" |
2324 "open a browser on the senders of some selector" |
2317 |
2325 |
2318 |initial selector| |
2326 |initial selector sel| |
2319 |
2327 |
2320 initial := codeView selection |
2328 (sel := codeView selection) notNil ifTrue:[ |
2321 ifNil:[selectedContext isNil |
2329 initial := BrowserView extractSelectorFrom:sel |
|
2330 ]. |
|
2331 initial isNil ifTrue:[ |
|
2332 initial := selectedContext isNil |
2322 ifTrue:[nil] |
2333 ifTrue:[nil] |
2323 ifFalse:[selectedContext selector]]. |
2334 ifFalse:[selectedContext selector]. |
|
2335 ]. |
2324 selector := Dialog |
2336 selector := Dialog |
2325 request:'Selector to browse senders of:' |
2337 request:'Selector to browse senders of:' |
2326 initialAnswer:initial. |
2338 initialAnswer:initial. |
2327 selector size == 0 ifFalse:[ |
2339 selector size == 0 ifFalse:[ |
2328 SystemBrowser browseAllCallsOn:selector asSymbol. |
2340 SystemBrowser browseAllCallsOn:selector asSymbol. |
2329 ] |
2341 ] |
|
2342 |
|
2343 "Modified: / 6.2.2000 / 01:05:29 / cg" |
2330 ! |
2344 ! |
2331 |
2345 |
2332 copyWalkbackText |
2346 copyWalkbackText |
2333 "place the contents of the walkback view into the copy-paste buffer. |
2347 "place the contents of the walkback view into the copy-paste buffer. |
2334 This allows pasting it into some other view for printing ..." |
2348 This allows pasting it into some other view for printing ..." |
3616 simply enter the DebugViews-Windowgroup event loop. |
3630 simply enter the DebugViews-Windowgroup event loop. |
3617 effectively suspending event processing for the currently |
3631 effectively suspending event processing for the currently |
3618 active group. |
3632 active group. |
3619 " |
3633 " |
3620 SignalSet anySignal handle:[:ex | |
3634 SignalSet anySignal handle:[:ex | |
3621 |answer signal| |
3635 |answer signal eMsg| |
3622 |
3636 |
3623 signal := ex signal. |
3637 signal := ex signal. |
3624 |
3638 |
3625 DebuggingDebugger ~~ true ifTrue:[ |
3639 DebuggingDebugger ~~ true ifTrue:[ |
3626 "/ |
3640 "/ |
3681 ]. |
3695 ]. |
3682 ]. |
3696 ]. |
3683 |
3697 |
3684 self topView raiseDeiconified. |
3698 self topView raiseDeiconified. |
3685 |
3699 |
|
3700 eMsg := ex errorString. |
|
3701 (ex signal == MessageTracer breakpointSignal |
|
3702 or:[ex signal == Object haltSignal]) ifTrue:[ |
|
3703 eMsg := eMsg , Character cr asString , 'in ' , ex suspendedContext printString |
|
3704 ]. |
|
3705 |
3686 answer := Dialog |
3706 answer := Dialog |
3687 choose:('error in debugger:\' withCRs , ex errorString , '\\debug again ?' withCRs) |
3707 choose:('error in debugger:\' withCRs , eMsg , '\\debug again ?' withCRs) |
3688 labels:#( 'proceed' 'cancel' 'debug' ) |
3708 labels:#( 'proceed' 'cancel' 'debug' ) |
3689 values:#( #proceed #cancel #debug ) |
3709 values:#( #proceed #cancel #debug ) |
3690 default:#cancel. |
3710 default:#cancel. |
3691 answer == #debug ifTrue:[ |
3711 answer == #debug ifTrue:[ |
3692 'DebugView [info]: cought exception - debugging' infoPrintCR. |
3712 'DebugView [info]: cought exception - debugging' infoPrintCR. |
3693 Debugger |
3713 Debugger |
3694 enterUnconditional:(ex suspendedContext) |
3714 enterUnconditional:(ex suspendedContext) |
3695 withMessage:'error in debugger: ' , ex errorString |
3715 withMessage:'error in debugger: ' , eMsg |
3696 mayProceed:true. |
3716 mayProceed:true. |
3697 ex proceed. |
3717 ex proceed. |
3698 ]. |
3718 ]. |
3699 answer == #proceed ifTrue:[ |
3719 answer == #proceed ifTrue:[ |
3700 'DebugView [info]: ignored exception - proceeding' infoPrintCR. |
3720 'DebugView [info]: ignored exception - proceeding' infoPrintCR. |