The Inbox: Kernel-cmm.1371.mcz

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

The Inbox: Kernel-cmm.1371.mcz

commits-2
Chris Muller uploaded a new version of Kernel to project The Inbox:
http://source.squeak.org/inbox/Kernel-cmm.1371.mcz

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

Name: Kernel-cmm.1371
Author: cmm
Time: 15 February 2021, 11:51:24.851653 pm
UUID: 4a74e7a0-6654-491e-8a64-685c44d6fb63
Ancestors: Kernel-dtl.1369

Let Processes identify themselves by a dynamic #name in their #printString IF they were so intentionally named, otherwise, the classic generic printString indicating its current Context.

=============== Diff against Kernel-dtl.1369 ===============

Item was changed:
  ----- Method: Process>>longPrintOn: (in category 'printing') -----
+ longPrintOn: stream
- longPrintOn: stream
-
  | ctxt |
+ self printOn: stream.
- super printOn: stream.
- stream
- nextPut: $(;
- nextPutAll: self name;
- nextPut: $).
  stream cr.
  ctxt := self suspendedContext.
+ [ ctxt == nil ] whileFalse:
+ [ stream space.
- [ctxt == nil] whileFalse: [
- stream space.
  ctxt printOn: stream.
  stream cr.
+ ctxt := ctxt sender ]!
- ctxt := ctxt sender.
- ].
- !

Item was changed:
  ----- Method: Process>>name (in category 'accessing') -----
  name
+ ^ name value
+ ifNil: [ self hash asString forceTo: 5 paddingStartWith: $ ]!
-
- ^name ifNil: [ self hash asString forceTo: 5 paddingStartWith: $ ]!

Item was changed:
  ----- Method: Process>>printOn: (in category 'printing') -----
+ printOn: aStream
+ self name
+ ifNil:
+ [ super printOn: aStream.
+ aStream nextPutAll: ' in '.
+ self suspendedContext printOn: aStream ]
+ ifNotNil:
+ [ : nm | aStream nextPutAll: nm ]!
- printOn: aStream
-
- super printOn: aStream.
- aStream
- nextPut: $(;
- nextPutAll: self name;
- nextPut: $).
- aStream nextPutAll: ' in '.
- suspendedContext printOn: aStream!