Eliot Miranda uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-eem.732.mcz
==================== Summary ====================
Name: Kernel-eem.732
Author: eem
Time: 6 February 2013, 1:10:49.952 pm
UUID: d9c124ab-9da1-4785-bfa3-341b385fffcb
Ancestors: Kernel-nice.731
Make CompiledMethod>>removeProperty:[ifAbsent:] get rid
of the AdditionalMethodState if the resulting state is empty.
Streamline BlockClosure>>newProcess[With:] which does
not need to run unwinds if control reaches the end of
the process.
Use the abstract blockCreationBytecodeMessage to compute
BlockClosure's size instead of accessing bytecodes directly.
=============== Diff against Kernel-nice.731 ===============
Item was changed:
----- Method: BlockClosure>>newProcess (in category 'scheduling') -----
newProcess
"Answer a Process running the code in the receiver. The process is not
scheduled."
<primitive: 19> "Simulation guard"
^Process
forContext:
[self value.
+ "Since control is now at the bottom there is no need to terminate (which
+ runs unwinds) since all unwnds have been run. Simply suspend.
+ Note that we must use this form rather than e.g. Processor suspendActive
+ so that isTerminated answers true. isTerminated requires that if there is a
+ suspended context it is the bottom-most, but using a send would result in
+ the process's suspendedContext /not/ being the bottom-most."
+ Processor activeProcess suspend] asContext
- Processor terminateActive] asContext
priority: Processor activePriority!
Item was changed:
----- Method: BlockClosure>>newProcessWith: (in category 'scheduling') -----
newProcessWith: anArray
"Answer a Process running the code in the receiver. The receiver's block
arguments are bound to the contents of the argument, anArray. The
process is not scheduled."
<primitive: 19> "Simulation guard"
^Process
forContext:
[self valueWithArguments: anArray.
+ "Since control is now at the bottom there is no need to terminate (which
+ runs unwinds) since all unwnds have been run. Simply suspend.
+ Note that we must use this form rather than e.g. Processor suspendActive
+ so that isTerminated answers true. isTerminated requires that if there is a
+ suspended context it is the bottom-most, but using a send would result in
+ the process's suspendedContext /not/ being the bottom-most."
+ Processor activeProcess suspend] asContext
- Processor terminateActive] asContext
priority: Processor activePriority!
Item was changed:
----- Method: BlockClosure>>size (in category 'accessing') -----
size
+ "Extract this closure's bytecode size (number of bytes) by accessing
+ the closure creation bytecode in the enclosing method."
- "Extract this closure's bytecode size (number of bytes) by accessing the closure
- creation bytecode in the enclosing method."
+ ^self blockCreationBytecodeMessage arguments last!
- ^ ((self method at: self startpc - 2) bitShift: 8) + (self method at: self startpc - 1)!
Item was changed:
----- Method: CompiledMethod>>removeProperty: (in category 'accessing-pragmas & properties') -----
removeProperty: propName
"Remove the property propName if it exists.
Do _not_ raise an error if the property is missing."
+ | value newAdditionalState |
- | value |
value := self propertyValueAt: propName ifAbsent: [^nil].
+ newAdditionalState := self penultimateLiteral copyWithout:
- self penultimateLiteral: (self penultimateLiteral copyWithout:
(Association
key: propName
+ value: value).
+ self penultimateLiteral: (newAdditionalState isEmpty
+ ifTrue: [newAdditionalState selector]
+ ifFalse: [newAdditionalState]).
- value: value)).
^value!
Item was changed:
----- Method: CompiledMethod>>removeProperty:ifAbsent: (in category 'accessing-pragmas & properties') -----
removeProperty: propName ifAbsent: aBlock
"Remove the property propName if it exists.
Answer the evaluation of aBlock if the property is missing."
+ | value newAdditionalState |
- | value |
value := self propertyValueAt: propName ifAbsent: [^aBlock value].
+ newAdditionalState := self penultimateLiteral copyWithout:
- self penultimateLiteral: (self penultimateLiteral copyWithout:
(Association
key: propName
+ value: value).
+ self penultimateLiteral: (newAdditionalState isEmpty
+ ifTrue: [newAdditionalState selector]
+ ifFalse: [newAdditionalState]).
- value: value)).
^value!
On 5 February 2013 03:47, <commits(a)source.squeak.org> wrote:
> Chris Muller uploaded a new version of SUnit to project The Trunk:
> http://source.squeak.org/trunk/SUnit-cmm.90.mcz
>
> ==================== Summary ====================
>
> Name: SUnit-cmm.90
> Author: cmm
> Time: 4 January 2013, 3:33:36.616 pm
> UUID: 8533f0b4-2587-412b-b465-4ad7f20331d0
> Ancestors: SUnit-ul.89
>
> - Do not wipe out pre-initialized state on TestCases. Tests do not need to be prevented from running more than once if proper setUp/tearDown methods are present.
>
> =============== Diff against SUnit-ul.89 ===============
>
> Item was changed:
> ----- Method: TestCase>>debug (in category 'running') -----
> debug
> + self resources do:
> + [ : res | res isAvailable ifFalse: [ ^ res signalInitializationError ] ].
> + [ self runCase ] ensure:
> + [ self resources do:
> + [ : each | each reset ] ]!
> - self resources do: [:res |
> - res isAvailable ifFalse: [^res signalInitializationError]].
> - [(self class selector: testSelector) runCase]
> - ensure: [self resources do: [:each | each reset]]
> - !
>
>
I think this breaks a test:
http://build.squeak.org/job/SqueakTrunk/148/testReport/junit/SUnit.Tests/SU…
Error Message
Assertion failed
Stacktrace
SUnitTest(TestCase)>>signalFailure:
SUnitTest(TestCase)>>assert:
SUnitTest>>testRanOnlyOnce
SUnitTest(TestCase)>>performTest
[] in [] in SUnitTest(TestCase)>>runCase
BlockClosure>>on:do:
[] in SUnitTest(TestCase)>>timeout:after:
BlockClosure>>ensure:
SUnitTest(TestCase)>>timeout:after:
[] in SUnitTest(TestCase)>>runCase
BlockClosure>>ensure:
SUnitTest(TestCase)>>runCase
[] in SUnitTest(TestCase)>>debug
BlockClosure>>ensure:
SUnitTest(TestCase)>>debug
SUnitTest>>testIsNotRerunOnDebug
SUnitTest(TestCase)>>performTest
frank
A new version of Compiler was added to project The Inbox:
http://source.squeak.org/inbox/Compiler.quasiquote-eem.249.mcz
==================== Summary ====================
Name: Compiler.quasiquote-eem.249
Author: eem
Time: 6 February 2013, 9:33:57.257 am
UUID: e3c0a389-e2f8-4b65-b611-4d09089f4237
Ancestors: Compiler.quasiquote-eem.248
New version that uses $ for escaping $ ` and [.
Add a quasi-quote form that allows convenient embedding
of substrings within a format string, and provides a
convenient way of embedding literal strings within an
alternative literal string whose string delimiter is different.
e.g.
`hello [#cruel] world!`
evaluates to
'hello cruel world'.
`S1[B1]...SN[BN]SN+1`
is equivalent to
{ 'S1'. [B1] value. ... 'SN'. [BN] value. 'SN+1' } concatenateQuasiQuote
where concatenateQuasiQuote sends asString to each
element and answers the concatenation of those elements.
however, single-statement blocks are inlined, so e.g. the
above `hello [#cruel] world!` is compiled as
{ 'hello '. #cruel. ' world!' } concatenateQuasiQuote
See Tests.quasiquote-eem.189 for tests and examples.
=============== Diff against Compiler.quasiquote-eem.248 ===============
Item was changed:
----- Method: MessageNode>>printQuasiQuoteOn:indent: (in category 'printing') -----
printQuasiQuoteOn: aStream indent: level
aStream nextPut: $`.
receiver elements do:
[:parseNode|
(parseNode isLiteralNode
and: [parseNode key class == 'literal' class])
ifTrue:
[parseNode key do:
[:char|
+ ('$`[' includes: char) ifTrue:
+ [aStream nextPut: $$].
- ('`[\' includes: char) ifTrue:
- [aStream nextPut: $\].
aStream nextPut: char]]
ifFalse:
[(parseNode isMessageNode
and: [parseNode selector key == #value
and: [parseNode receiver isBlockNode]])
ifTrue:
[parseNode receiver printOn: aStream indent: 0]
ifFalse:
[aStream nextPut: $[.
parseNode printOn: aStream indent: 0.
aStream nextPut: $]]]].
aStream nextPut: $`!
Item was changed:
----- Method: Parser>>scanQuasiQuoteCharactersUsing: (in category 'scanning') -----
scanQuasiQuoteCharactersUsing: stringStream
"Answer the next non-empty sequence of characters in a quasi-quote string, or nil, if none."
stringStream reset.
[hereChar ~~ $` and: [hereChar ~~ $[ and: [hereChar ~~ DoItCharacter]]] whileTrue:
+ [(hereChar == $$ and: ['`[$' includes: aheadChar])
- [hereChar == $\
ifTrue:
[stringStream nextPut: aheadChar. self step]
ifFalse:
[stringStream nextPut: hereChar].
self step].
self setHereTypeForQuasiQuote.
^stringStream position > 0 ifTrue:
[encoder encodeLiteral: stringStream contents]!
In the Etoys image we found a very old bug in morphic that I'm not sure how
to fix.
You can test it by trying to rotate a FlapTab in any Squeak image older
than 3.1b.
For a very hard image lockup try rotating the FlapTab with the flap open.
Then opening the debugger fails also.
The bug appeared between images Squeak 3.1b and Squeak 3.2 so it has been
around a while.
The bug is with creating a TransformationMorph that has fullBounds nil.
TransformMorph overrides fullBounds:
fullBounds ifNotNil:[^ fullBounds].
fullBounds := bounds.
submorphs do: [:m| m ownerChanged].
^ fullBounds
Even if bounds are not nil, fullBounds gets nil'ed again when calling
submorphs ownerChanged.
Any hints and good solutions appreciated :-)
Karl
On Sun, Feb 3, 2013 at 9:18 PM, Karl Ramberg (JIRA)
<tracker(a)squeakland.org>wrote:
>
> [
> http://tracker.squeakland.org/browse/SQ-1119?page=com.atlassian.jira.plugin…]
>
> Karl Ramberg commented on SQ-1119:
> ----------------------------------
>
> It is really the FlapTab that has some issues with rotation.
>
> Somehow the TransformationMorph fails with nil fullBounds.
>
> I'm not sure how that can happen...
>
>
> VM: Win32 - a SmalltalkImage
> Image: etoys5.0 [latest update: #2409]
>
>
> UndefinedObject(Object)>>doesNotUnderstand: #hasPositiveExtent
> Receiver: nil
> Arguments and temporary variables:
> aMessage: hasPositiveExtent
> Receiver's instance variables:
> nil
>
> TransformationMorph(Morph)>>invalidRect:from:
> Receiver: a TransformationMorph(2153) on a FlapTab<Flap>(1211) "My
> Flap"
> Arguments and temporary variables:
> aRectangle: nil
> aMorph: a TransformationMorph(2153) on a
> FlapTab<Flap>(1211) "My Flap"
> damageRect: nil
> Receiver's instance variables:
> bounds: 99@105 corner: 207@132
> owner: nil
> submorphs: #(a FlapTab<Flap>(1211) "My Flap")
> fullBounds: nil
> color: Color lightGreen
> extension: nil
> transform: a MorphicTransform(angle = 0.0; scale =
> 1.0; offset = 0@0)
> smoothing: 1
> localBounds: nil
>
> TransformationMorph(TransformMorph)>>invalidRect:from:
> Receiver: a TransformationMorph(2153) on a FlapTab<Flap>(1211) "My
> Flap"
> Arguments and temporary variables:
> damageRect: nil
> aMorph: a TransformationMorph(2153) on a
> FlapTab<Flap>(1211) "My Flap"
> Receiver's instance variables:
> bounds: 99@105 corner: 207@132
> owner: nil
> submorphs: #(a FlapTab<Flap>(1211) "My Flap")
> fullBounds: nil
> color: Color lightGreen
> extension: nil
> transform: a MorphicTransform(angle = 0.0; scale =
> 1.0; offset = 0@0)
> smoothing: 1
> localBounds: nil
>
> TransformationMorph(Morph)>>invalidRect:
> Receiver: a TransformationMorph(2153) on a FlapTab<Flap>(1211) "My
> Flap"
> Arguments and temporary variables:
> damageRect: nil
> Receiver's instance variables:
> bounds: 99@105 corner: 207@132
> owner: nil
> submorphs: #(a FlapTab<Flap>(1211) "My Flap")
> fullBounds: nil
> color: Color lightGreen
> extension: nil
> transform: a MorphicTransform(angle = 0.0; scale =
> 1.0; offset = 0@0)
> smoothing: 1
> localBounds: nil
>
>
> --- The full stack ---
> UndefinedObject(Object)>>doesNotUnderstand: #hasPositiveExtent
> TransformationMorph(Morph)>>invalidRect:from:
> TransformationMorph(TransformMorph)>>invalidRect:from:
> TransformationMorph(Morph)>>invalidRect:
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> TransformationMorph(Morph)>>position:
> TransformationMorph>>asFlexOf:
> FlapTab(Morph)>>addFlexShell
> FlapTab(Morph)>>addFlexShellIfNecessary
> HaloMorph>>startRot:with:
> EventHandler>>send:to:withEvent:fromMorph:
> EventHandler>>mouseDown:fromMorph:
> ThreePhaseButtonMorph(Morph)>>mouseDown:
> ThreePhaseButtonMorph>>mouseDown:
> ThreePhaseButtonMorph(Morph)>>handleMouseDown:
> MouseButtonEvent>>sentTo:
> ThreePhaseButtonMorph(Morph)>>handleEvent:
> MorphicEventDispatcher>>dispatchMouseDown:with:
> MorphicEventDispatcher>>dispatchEvent:with:
> ThreePhaseButtonMorph(Morph)>>processEvent:using:
> MorphicEventDispatcher>>dispatchMouseDown:with:
> MorphicEventDispatcher>>dispatchEvent:with:
> HaloMorph(Morph)>>processEvent:using:
> MorphicEventDispatcher>>dispatchMouseDown:with:
> MorphicEventDispatcher>>dispatchEvent:with:
> PasteUpMorph(Morph)>>processEvent:using:
> PasteUpMorph>>processEvent:using:
> PasteUpMorph(Morph)>>processEvent:
> HandMorph>>sendEvent:focus:clear:
> HandMorph>>sendMouseEvent:
> HandMorph>>handleEvent:
> HandMorph>>processEvents
> [] in WorldState>>doOneCycleNowFor: {[:h | ActiveHand := h. h
> processEvents. capturingGesture := capturingGest...]}
> Array(SequenceableCollection)>>do:
> WorldState>>handsDo:
> WorldState>>doOneCycleNowFor:
> WorldState>>doOneCycleFor:
> PasteUpMorph>>doOneCycle
> [] in Project class>>spawnNewProcess {[[World doOneCycle. Processor
> yield. false] whileFalse. nil]}
> [] in BlockContext>>newProcess {[self value. Processor terminateActive]}
>
>
> > Rotating flaps DNU and other mishaps
> > ------------------------------------
> >
> > Key: SQ-1119
> > URL: http://tracker.squeakland.org/browse/SQ-1119
> > Project: squeakland
> > Issue Type: Bug
> > Components: etoys
> > Reporter: Karl Ramberg
> > Fix For: future release
> >
> >
> > Most flaps can be rotated by rotation handle but none of them do this
> gracefully. Viewer flaps give DNU when collapsed and opened again. 'About'
> flap leaves a green transformation morph on the desktop.
> > Should we disable the rotation handle for flaps ?
> > I can't really see a use case for rotating a flap, except for a cool
> factor ;-)
>
> --
> This message is automatically generated by JIRA.
> -
> If you think it was sent incorrectly contact one of the administrators:
> http://tracker.squeakland.org/secure/Administrators.jspa
> -
> For more information on JIRA, see: http://www.atlassian.com/software/jira
>
>
>