The Trunk: CommandLine-mt.14.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: CommandLine-mt.14.mcz

commits-2
Marcel Taeumel uploaded a new version of CommandLine to project The Trunk:
http://source.squeak.org/trunk/CommandLine-mt.14.mcz

==================== Summary ====================

Name: CommandLine-mt.14
Author: mt
Time: 17 September 2019, 12:14:25.642406 pm
UUID: b5e83276-0986-e641-8586-162ae1c5c811
Ancestors: CommandLine-pre.13

Refactoring of process debugging. Complements System-mt.1093

=============== Diff against CommandLine-pre.13 ===============

Item was removed:
- ----- Method: CommandLineToolSet class>>debugContext:label:contents: (in category 'debugging') -----
- debugContext: aContext label: aString contents: contents
- "We can't open a command line debugger, so just log the error and carry on."
- | s |
- s := FileStream stderr.
- s
- nextPutAll: self className;
- nextPutAll: ': ';
- nextPutAll: aString;
- cr;
- nextPutAll: contents;
- cr.
- (aContext stackOfSize: 20) do: [:ctx | ctx printOn: s. s cr].
- s flush.!

Item was removed:
- ----- Method: CommandLineToolSet class>>debugError: (in category 'debugging') -----
- debugError: anError
- "Print out a sensible stack trace and bail"
- self saveSnapshotOnError ifTrue: [ Smalltalk saveAs: 'Debug-' , Smalltalk imageEntry name ].
- anError printVerboseOn: FileStream stderr.
- FileStream stderr flush.
- Smalltalk
- snapshot: false
- andQuit: true!

Item was added:
+ ----- Method: CommandLineToolSet class>>debugMethod:forReceiver:inContext: (in category 'debugging') -----
+ debugMethod: aCompiledMethod forReceiver: anObject inContext: aContext
+ "We can't open a command line debugger, so just log the event, run that method, and carry on."
+
+ FileStream stderr
+ nextPutAll: self className;
+ nextPutAll: ': Debug Method';
+ cr;
+ nextPutAll: aCompiledMethod getSource asString;
+ cr;
+ nextPutAll: anObject printString;
+ cr;
+ nextPutAll: aContext printString;
+ flush.
+
+ aCompiledMethod
+ valueWithReceiver: anObject
+ arguments: (aContext ifNil: [#()] ifNotNil: [{aContext}]).!

Item was added:
+ ----- Method: CommandLineToolSet class>>debugProcess:context:label:contents:fullView: (in category 'debugging') -----
+ debugProcess: aProcess context: aContext label: aString contents: contents fullView: aBool
+ "We can't open a command line debugger, so just log the error and carry on."
+
+ | s |
+ s := FileStream stderr.
+ s
+ nextPutAll: self className;
+ nextPutAll: ': ';
+ nextPutAll: aString;
+ cr;
+ nextPutAll: contents;
+ cr.
+ (aContext stackOfSize: 20) do: [:ctx | ctx printOn: s. s cr].
+ s flush.!

Item was removed:
- ----- Method: CommandLineToolSet class>>debugSyntaxError: (in category 'debugging') -----
- debugSyntaxError: anError
- FileStream stderr
- nextPutAll: '----- Syntax error -----' ;
- cr ;
- nextPutAll: anError errorCode ;
- cr ;
- nextPutAll: '----- Syntax error -----' ;
- cr ;
- flush.
- self debugError: anError!

Item was added:
+ ----- Method: CommandLineToolSet class>>handleError: (in category 'debugging - handlers') -----
+ handleError: anError
+ "Print out a sensible stack trace and bail"
+ self saveSnapshotOnError ifTrue: [ Smalltalk saveAs: 'Debug-' , Smalltalk imageEntry name ].
+ anError printVerboseOn: FileStream stderr.
+ FileStream stderr flush.
+ Smalltalk
+ snapshot: false
+ andQuit: true!

Item was added:
+ ----- Method: CommandLineToolSet class>>handleSyntaxError: (in category 'debugging - handlers') -----
+ handleSyntaxError: anError
+ FileStream stderr
+ nextPutAll: '----- Syntax error -----' ;
+ cr ;
+ nextPutAll: anError errorCode ;
+ cr ;
+ nextPutAll: '----- Syntax error -----' ;
+ cr ;
+ flush.
+ self handleError: anError!

Item was added:
+ ----- Method: CommandLineToolSet class>>handleUserInterruptRequest: (in category 'debugging - handlers') -----
+ handleUserInterruptRequest: aString
+
+ self saveSnapshotOnError ifTrue: [ Smalltalk saveAs: 'Debug-' , Smalltalk imageEntry name ].
+
+ FileStream stderr nextPutAll: aString.
+ FileStream stderr flush.
+ Smalltalk
+ snapshot: false
+ andQuit: true!

Item was added:
+ ----- Method: CommandLineToolSet class>>handleWarning: (in category 'debugging - handlers') -----
+ handleWarning: aWarning
+
+ self handleError: aWarning.!

Item was removed:
- ----- Method: DummyUIManager>>openDebugger:on:context:label:contents:fullView: (in category 'ui project indirecting') -----
- openDebugger: aDebugger on: process context: context label: title contents: contentsStringOrNil fullView: bool
- "open a debugger - the two versions for mvc & morphic are very close and can surely be merged so that this can be removed"
- ^nil!

Item was removed:
- ----- Method: DummyUIManager>>resumeDebugger:process: (in category 'ui project indirecting') -----
- resumeDebugger: aDebugger process: aTopView
- "resume a debugger - the two versions for mvc & morphic are very close and can surely be merged so that this can be removed"
- ^nil!