The Inbox: System-ct.1128.mcz

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

The Inbox: System-ct.1128.mcz

commits-2
A new version of System was added to project The Inbox:
http://source.squeak.org/inbox/System-ct.1128.mcz

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

Name: System-ct.1128
Author: ct
Time: 14 December 2019, 3:14:14.108612 pm
UUID: 89698e0d-cee3-2041-afa8-96674d632912
Ancestors: System-mt.1127

Extends Transcripter with #clear command and refactors readEvalPrint loop

- Adds #showln: method

=============== Diff against System-mt.1127 ===============

Item was changed:
  ----- Method: Transcripter>>readEvalPrint (in category 'command line') -----
  readEvalPrint
  | line okToRevert |
  okToRevert := true.
+ [#(quit exit done) includes: (line := self request: '>')]
+ whileFalse: [ line
+ caseOf: {
+ [#revert] -> [okToRevert
+ ifTrue: [RecentMessages default revertMostRecent.
+ self showln: 'reverted: ' , RecentMessages default mostRecent.
+ okToRevert := false]
+ ifFalse: [self showln: 'Only one level of revert currently supported']].
+ [#clear] -> [self clear]. }
+ otherwise: [
+ self showln: ([Compiler evaluate: line] ifError: [:err :ex | err])] ]!
- [#('quit' 'exit' 'done' ) includes: (line := self request: '>')]
- whileFalse:
- [line = 'revert'
- ifTrue: [okToRevert
- ifTrue: [RecentMessages default revertMostRecent.
- self cr; show: 'reverted: ' , RecentMessages default mostRecent.
- okToRevert := false]
- ifFalse: [self cr; show: 'Only one level of revert currently supported']]
- ifFalse: [self cr; show: ([Compiler evaluate: line] ifError: [:err :ex | err])]]!

Item was added:
+ ----- Method: Transcripter>>showln: (in category 'accessing') -----
+ showln: anObject
+ self
+ cr;
+ show: anObject!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

Tobias Pape
That would be #lnshow: not #showln: righ? ;)

Best regards
        -tobias
> On 14.12.2019, at 15:14, [hidden email] wrote:
>
> + ----- Method: Transcripter>>showln: (in category 'accessing') -----
> + showln: anObject
> + self
> + cr;
> + show: anObject!



Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

Christoph Thiede

In TranscriptStream, #showln: prints the newline first as well :-)




Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Tobias Pape <[hidden email]>
Gesendet: Sonntag, 15. Dezember 2019 12:21:14
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] The Inbox: System-ct.1128.mcz
 
That would be #lnshow: not #showln: righ? ;)

Best regards
        -tobias
> On 14.12.2019, at 15:14, [hidden email] wrote:
>
> + ----- Method: Transcripter>>showln: (in category 'accessing') -----
> + showln: anObject
> +      self
> +              cr;
> +              show: anObject!





Carpe Squeak!
Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

Tobias Pape

> On 16.12.2019, at 11:57, Thiede, Christoph <[hidden email]> wrote:
>
> In TranscriptStream, #showln: prints the newline first as well :-)
>

oof :D
        -Tobias

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

marcel.taeumel
In reply to this post by commits-2
Hi Christoph,

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

In TranscriptStream, #showln: prints the newline first as well

I added that to TranscriptStream to make sure that even the first call to #showln: is on an extra line, regardless of its previous contents.

Best,
Marcel

Am 15.12.2019 12:15:18 schrieb [hidden email] <[hidden email]>:

A new version of System was added to project The Inbox:
http://source.squeak.org/inbox/System-ct.1128.mcz

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

Name: System-ct.1128
Author: ct
Time: 14 December 2019, 3:14:14.108612 pm
UUID: 89698e0d-cee3-2041-afa8-96674d632912
Ancestors: System-mt.1127

Extends Transcripter with #clear command and refactors readEvalPrint loop

- Adds #showln: method

=============== Diff against System-mt.1127 ===============

Item was changed:
----- Method: Transcripter>>readEvalPrint (in category 'command line') -----
readEvalPrint
| line okToRevert |
okToRevert := true.
+ [#(quit exit done) includes: (line := self request: '>')]
+ whileFalse: [ line
+ caseOf: {
+ [#revert] -> [okToRevert
+ ifTrue: [RecentMessages default revertMostRecent.
+ self showln: 'reverted: ' , RecentMessages default mostRecent.
+ okToRevert := false]
+ ifFalse: [self showln: 'Only one level of revert currently supported']].
+ [#clear] -> [self clear]. }
+ otherwise: [
+ self showln: ([Compiler evaluate: line] ifError: [:err :ex | err])] ]!
- [#('quit' 'exit' 'done' ) includes: (line := self request: '>')]
- whileFalse:
- [line = 'revert'
- ifTrue: [okToRevert
- ifTrue: [RecentMessages default revertMostRecent.
- self cr; show: 'reverted: ' , RecentMessages default mostRecent.
- okToRevert := false]
- ifFalse: [self cr; show: 'Only one level of revert currently supported']]
- ifFalse: [self cr; show: ([Compiler evaluate: line] ifError: [:err :ex | err])]]!

Item was added:
+ ----- Method: Transcripter>>showln: (in category 'accessing') -----
+ showln: anObject
+ self
+ cr;
+ show: anObject!




Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

Christoph Thiede

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

Minimality might be a general goal for sustainable software development :) I just wanted to avoid to repeat myself.

Best,
Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Taeumel, Marcel
Gesendet: Montag, 16. Dezember 2019 19:37:15
An: John Pfersich via Squeak-dev
Betreff: Re: [squeak-dev] The Inbox: System-ct.1128.mcz
 
Hi Christoph,

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

In TranscriptStream, #showln: prints the newline first as well

I added that to TranscriptStream to make sure that even the first call to #showln: is on an extra line, regardless of its previous contents.

Best,
Marcel

Am 15.12.2019 12:15:18 schrieb [hidden email] <[hidden email]>:

A new version of System was added to project The Inbox:
http://source.squeak.org/inbox/System-ct.1128.mcz

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

Name: System-ct.1128
Author: ct
Time: 14 December 2019, 3:14:14.108612 pm
UUID: 89698e0d-cee3-2041-afa8-96674d632912
Ancestors: System-mt.1127

Extends Transcripter with #clear command and refactors readEvalPrint loop

- Adds #showln: method

=============== Diff against System-mt.1127 ===============

Item was changed:
----- Method: Transcripter>>readEvalPrint (in category 'command line') -----
readEvalPrint
| line okToRevert |
okToRevert := true.
+ [#(quit exit done) includes: (line := self request: '>')]
+ whileFalse: [ line
+ caseOf: {
+ [#revert] -> [okToRevert
+ ifTrue: [RecentMessages default revertMostRecent.
+ self showln: 'reverted: ' , RecentMessages default mostRecent.
+ okToRevert := false]
+ ifFalse: [self showln: 'Only one level of revert currently supported']].
+ [#clear] -> [self clear]. }
+ otherwise: [
+ self showln: ([Compiler evaluate: line] ifError: [:err :ex | err])] ]!
- [#('quit' 'exit' 'done' ) includes: (line := self request: '>')]
- whileFalse:
- [line = 'revert'
- ifTrue: [okToRevert
- ifTrue: [RecentMessages default revertMostRecent.
- self cr; show: 'reverted: ' , RecentMessages default mostRecent.
- okToRevert := false]
- ifFalse: [self cr; show: 'Only one level of revert currently supported']]
- ifFalse: [self cr; show: ([Compiler evaluate: line] ifError: [:err :ex | err])]]!

Item was added:
+ ----- Method: Transcripter>>showln: (in category 'accessing') -----
+ showln: anObject
+ self
+ cr;
+ show: anObject!




Carpe Squeak!
Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

marcel.taeumel
Hi Christoph.

Minimality might be a general goal for sustainable software development

Of course! But I gave that comment for a different reason. The EmergencyEvaluator is the last resort for recovery in the interactive system. We should carefully choose and design the amount of features to keep it as robust as possible. The less features, the better.

More fancy fallbacks for Morphic are the MVC debugger or the Squeak Shell. :-) Just install them as your parent project.

Best,
Marcel

Am 16.12.2019 19:51:43 schrieb Thiede, Christoph <[hidden email]>:

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

Minimality might be a general goal for sustainable software development :) I just wanted to avoid to repeat myself.

Best,
Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Taeumel, Marcel
Gesendet: Montag, 16. Dezember 2019 19:37:15
An: John Pfersich via Squeak-dev
Betreff: Re: [squeak-dev] The Inbox: System-ct.1128.mcz
 
Hi Christoph,

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

In TranscriptStream, #showln: prints the newline first as well

I added that to TranscriptStream to make sure that even the first call to #showln: is on an extra line, regardless of its previous contents.

Best,
Marcel

Am 15.12.2019 12:15:18 schrieb [hidden email] <[hidden email]>:

A new version of System was added to project The Inbox:
http://source.squeak.org/inbox/System-ct.1128.mcz

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

Name: System-ct.1128
Author: ct
Time: 14 December 2019, 3:14:14.108612 pm
UUID: 89698e0d-cee3-2041-afa8-96674d632912
Ancestors: System-mt.1127

Extends Transcripter with #clear command and refactors readEvalPrint loop

- Adds #showln: method

=============== Diff against System-mt.1127 ===============

Item was changed:
----- Method: Transcripter>>readEvalPrint (in category 'command line') -----
readEvalPrint
| line okToRevert |
okToRevert := true.
+ [#(quit exit done) includes: (line := self request: '>')]
+ whileFalse: [ line
+ caseOf: {
+ [#revert] -> [okToRevert
+ ifTrue: [RecentMessages default revertMostRecent.
+ self showln: 'reverted: ' , RecentMessages default mostRecent.
+ okToRevert := false]
+ ifFalse: [self showln: 'Only one level of revert currently supported']].
+ [#clear] -> [self clear]. }
+ otherwise: [
+ self showln: ([Compiler evaluate: line] ifError: [:err :ex | err])] ]!
- [#('quit' 'exit' 'done' ) includes: (line := self request: '>')]
- whileFalse:
- [line = 'revert'
- ifTrue: [okToRevert
- ifTrue: [RecentMessages default revertMostRecent.
- self cr; show: 'reverted: ' , RecentMessages default mostRecent.
- okToRevert := false]
- ifFalse: [self cr; show: 'Only one level of revert currently supported']]
- ifFalse: [self cr; show: ([Compiler evaluate: line] ifError: [:err :ex | err])]]!

Item was added:
+ ----- Method: Transcripter>>showln: (in category 'accessing') -----
+ showln: anObject
+ self
+ cr;
+ show: anObject!




Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-ct.1128.mcz

Christoph Thiede

Of course! But I gave that comment for a different reason. The EmergencyEvaluator is the last resort for recovery in the interactive system. We should carefully choose and design the amount of features to keep it as robust as possible. The less features, the better.


I agree :-) However, I found the #clear feature quite essential because sometimes, I am presented error messages here that take more than the available screen space.

(Btw, could we maybe always use Display boundingBox as the frame for the EE?)

More fancy fallbacks for Morphic are the MVC debugger or the Squeak Shell. :-) Just install them as your parent project.

Yes, I installed SqueakShell and it looks great :-) (And will look even greater when I manage to implement a CommandLineUIManager :-))
By the way, its Debugger integration still depends on the old ErrorRecursion classvar ...

Best,
Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Taeumel, Marcel
Gesendet: Montag, 16. Dezember 2019 19:56:30
An: John Pfersich via Squeak-dev
Betreff: Re: [squeak-dev] The Inbox: System-ct.1128.mcz
 
Hi Christoph.

Minimality might be a general goal for sustainable software development

Of course! But I gave that comment for a different reason. The EmergencyEvaluator is the last resort for recovery in the interactive system. We should carefully choose and design the amount of features to keep it as robust as possible. The less features, the better.

More fancy fallbacks for Morphic are the MVC debugger or the Squeak Shell. :-) Just install them as your parent project.

Best,
Marcel

Am 16.12.2019 19:51:43 schrieb Thiede, Christoph <[hidden email]>:

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

Minimality might be a general goal for sustainable software development :) I just wanted to avoid to repeat myself.

Best,
Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Taeumel, Marcel
Gesendet: Montag, 16. Dezember 2019 19:37:15
An: John Pfersich via Squeak-dev
Betreff: Re: [squeak-dev] The Inbox: System-ct.1128.mcz
 
Hi Christoph,

note that the implementation of Transcripter should be as minimal as possible. That new "clear" command is fine, I guess. :-)

In TranscriptStream, #showln: prints the newline first as well

I added that to TranscriptStream to make sure that even the first call to #showln: is on an extra line, regardless of its previous contents.

Best,
Marcel

Am 15.12.2019 12:15:18 schrieb [hidden email] <[hidden email]>:

A new version of System was added to project The Inbox:
http://source.squeak.org/inbox/System-ct.1128.mcz

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

Name: System-ct.1128
Author: ct
Time: 14 December 2019, 3:14:14.108612 pm
UUID: 89698e0d-cee3-2041-afa8-96674d632912
Ancestors: System-mt.1127

Extends Transcripter with #clear command and refactors readEvalPrint loop

- Adds #showln: method

=============== Diff against System-mt.1127 ===============

Item was changed:
----- Method: Transcripter>>readEvalPrint (in category 'command line') -----
readEvalPrint
| line okToRevert |
okToRevert := true.
+ [#(quit exit done) includes: (line := self request: '>')]
+ whileFalse: [ line
+ caseOf: {
+ [#revert] -> [okToRevert
+ ifTrue: [RecentMessages default revertMostRecent.
+ self showln: 'reverted: ' , RecentMessages default mostRecent.
+ okToRevert := false]
+ ifFalse: [self showln: 'Only one level of revert currently supported']].
+ [#clear] -> [self clear]. }
+ otherwise: [
+ self showln: ([Compiler evaluate: line] ifError: [:err :ex | err])] ]!
- [#('quit' 'exit' 'done' ) includes: (line := self request: '>')]
- whileFalse:
- [line = 'revert'
- ifTrue: [okToRevert
- ifTrue: [RecentMessages default revertMostRecent.
- self cr; show: 'reverted: ' , RecentMessages default mostRecent.
- okToRevert := false]
- ifFalse: [self cr; show: 'Only one level of revert currently supported']]
- ifFalse: [self cr; show: ([Compiler evaluate: line] ifError: [:err :ex | err])]]!

Item was added:
+ ----- Method: Transcripter>>showln: (in category 'accessing') -----
+ showln: anObject
+ self
+ cr;
+ show: anObject!




Carpe Squeak!