Skip to content

Commit

Permalink
Merge pull request #25 from SeasideSt/bugfix-dynvar
Browse files Browse the repository at this point in the history
Fix for default value of GRDynamicVariable
  • Loading branch information
Johan Brichau authored Jul 23, 2017
2 parents 61126b9 + 8fc05b0 commit c9f536d
Show file tree
Hide file tree
Showing 71 changed files with 347 additions and 368 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,81 +15,31 @@ baseline: spec
group: 'Slime Tests' with: #('Core Tests');
group: 'Tests' with: #('Core Tests' 'Slime Tests');
group: 'default' with: #('Slime') ].
spec
for: #'squeak4.x'
do: [
spec
package: 'Grease-Core'
with: [ spec includes: #('Grease-Pharo-Core' 'Grease-Squeak-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Pharo-Core' 'Grease-Tests-Squeak-Core') ];
package: 'Grease-Pharo-Core' with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Pharo-Core'
with: [ spec requires: #('Grease-Tests-Core') ];
package: 'Grease-Squeak-Core'
with: [ spec requires: #('Grease-Pharo-Core') ];
package: 'Grease-Tests-Squeak-Core'
with: [ spec requires: #('Grease-Tests-Pharo-Core') ].
self slimeForSqueakPharo1xPharo2x: spec ].

spec
for: #'squeak5.x'
do: [
spec
package: 'Grease-Core'
with: [ spec includes: #('Grease-Squeak5-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Squeak-Core' 'Grease-Tests-Squeak5-Core') ];
with: [ spec requires: #('Grease-Squeak5-Core'); includes: #('Grease-Tests-Squeak-Core' 'Grease-Tests-Squeak5-Core') ];
package: 'Grease-Squeak5-Core'
with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Squeak-Core'
with: [ spec requires: #('Grease-Tests-Core') ];
package: 'Grease-Tests-Squeak5-Core'
with: [ spec requires: #('Grease-Tests-Squeak-Core') ].
self slimeForSqueakPharo1xPharo2x: spec ].
spec
for: #'pharo1.0'
do: [
spec
package: 'Grease-Pharo-Core'
with: [ spec includes: #('Grease-Pharo10-Core' 'Grease-Pharo11-Core') ] ].
spec
for: #'pharo1.x'
do: [
spec
package: 'Grease-Core' with: [ spec includes: #('Grease-Pharo-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Pharo-Core') ];
package: 'Grease-Pharo-Core' with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Pharo-Core'
with: [ spec requires: #('Grease-Tests-Core') ].
self slimeForSqueakPharo1xPharo2x: spec ].
spec
for: #'pharo1.1'
do: [
spec
package: 'Grease-Pharo-Core'
with: [ spec includes: #('Grease-Pharo11-Core') ] ].
spec
for: #'pharo2.x'
do: [
spec
package: 'Grease-Core'
with: [ spec includes: #('Grease-Pharo20-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Pharo20-Core') ];
package: 'Grease-Pharo20-Core'
with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Pharo20-Core'
with: [ spec requires: #('Grease-Tests-Core') ].
self slimeForSqueakPharo1xPharo2x: spec ].

spec
for: #'pharo3.x'
do: [
spec
package: 'Grease-Core'
with: [ spec includes: #('Grease-Pharo30-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Pharo20-Core') ];
with: [ spec requires: #('Grease-Pharo30-Core'); includes: #('Grease-Tests-Pharo20-Core') ];
package: 'Grease-Pharo30-Core'
with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Pharo20-Core'
Expand All @@ -107,7 +57,7 @@ baseline: spec
package: 'Grease-Core'
with: [ spec includes: #('Grease-Pharo30-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Pharo20-Core') ];
with: [ spec requires: #('Grease-Pharo30-Core'); includes: #('Grease-Tests-Pharo20-Core') ];
package: 'Grease-Pharo30-Core'
with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Pharo20-Core'
Expand All @@ -126,7 +76,7 @@ baseline: spec
package: 'Grease-Core'
with: [ spec includes: #('Grease-Pharo60-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-Pharo20-Core') ];
with: [ spec requires: #('Grease-Pharo60-Core'); includes: #('Grease-Tests-Pharo20-Core') ];
package: 'Grease-Pharo60-Core'
with: [ spec requires: #('Grease-Core') ];
package: 'Grease-Tests-Pharo20-Core'
Expand Down Expand Up @@ -168,7 +118,7 @@ baseline: spec
requires: #('GsCore');
includes: #('Grease-GemStone-Core') ];
package: 'Grease-Tests-Core'
with: [ spec includes: #('Grease-Tests-GemStone-Core') ];
with: [ spec requires: #('Grease-GemStone-Core'); includes: #('Grease-Tests-GemStone-Core') ];
package: 'Grease-GemStone-Core'
with: [
spec
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"instance" : {
"initializeLatin1ToUtf8Encodings" : "JohanBrichau 10/19/2014 10:00",
"slimeForSqueakPharo1xPharo2x:" : "JohanBrichau 02/16/2014 03:49",
"baseline:" : "JohanBrichau 5/25/2017 12:45"
"baseline:" : "JohanBrichau 7/23/2017 19:28"
},
"class" : { }
}
3 changes: 2 additions & 1 deletion repository/BaselineOfGrease.package/monticello.meta/version
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
(name 'BaselineOfGrease-JohanBrichau.18' message 'Pharo 6 compatibility' id 'd2d614aa-b80c-0d00-b4b6-ae9900bfc9db' date '25 May 2017' time '12:46:04.246978 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.17' message 'Added pharo6' id '52335469-982c-483b-a975-4518820b9bcf' date '25 May 2017' time '11:20:35.004053 am' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-dkh.16' message 'merged by GitFileTree-MergeDriver' id '644ab134-dd42-4b9f-948b-c277cd963d5d' date '26 August 2016' time '5:20:50.221776 am' author 'dkh' ancestors ((name 'BaselineOfGrease-dkh.15' message 'merged by GitFileTree-MergeDriver' id '86b6f4f6-f95f-4bd7-9224-f31c5460e354' date '4 April 2016' time '9:40:53.04415 am' author 'dkh' ancestors ((name 'BaselineOfGrease-dkh.10' message 'update for GemStone 3.4 ...' id 'ad7f9331-d83f-4976-bf57-1d1e81111fc6' date '21 December 2015' time '3:07:11 pm' author 'dkh' ancestors ((name 'BaselineOfGrease-dkh.9' message 'Update baseline for GemStone 3.3' id 'af9364dd-14bc-4e5e-9fc7-0abe08732ab2' date '26 May 2015' time '11:46:07 am' author 'dkh' ancestors ((name 'BaselineOfGrease-JohanBrichau.8' message 'separate package for Squeak' id '91c019c7-2b8b-40c3-97d9-2047a69512a7' date '22 March 2015' time '12:01:37 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.7' message 'included Pharo 4 and did some baseline formatting' id '3722041d-d4b5-4496-a25a-0e891fe9a945' date '8 November 2014' time '9:28:01 am' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.6' message 'added initializeLatin1ToUtf8Encodings' id '4d976044-1aa9-44b6-bab0-b66ac758b3cd' date '19 October 2014' time '10:05:25 am' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.6' message 'added initializeLatin1ToUtf8Encodings' id 'b4ac5766-d472-4557-beff-59e5b733bce0' date '19 October 2014' time '10:04:55 am' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-dkh.5' message 'typoe' id '93eb3230-7956-4a6e-85dc-243f3dd895a1' date '4 June 2014' time '3:13:26 pm' author 'dkh' ancestors ((name 'BaselineOfGrease-dkh.4' message 'woops specified the package branch incorrectly ... I think I got it right this time...' id '3003ee31-9d17-4dd1-9b9a-f8a80e4f0ba1' date '4 June 2014' time '3:12:31 pm' author 'dkh' ancestors ((name 'BaselineOfGrease-dkh.3' message 'add Grease-Tests-GemStone-Core.v32 to baseline' id '26f128ca-b62e-4295-9a58-a9758b670c37' date '4 June 2014' time '2:57:48 pm' author 'dkh' ancestors ((name 'BaselineOfGrease-JohanBrichau.2' message 'forgotten methods' id '38758da9-c922-4530-a19e-f8783900e787' date '16 February 2014' time '3:50:22 am' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.1' message 'first baseline' id 'b89398df-14c6-4b6a-a2ba-91ad806bb07f' date '16 February 2014' time '1:49:46 am' author 'JohanBrichau' ancestors () stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())(name 'BaselineOfGrease-JohanBrichau.14' message 'Ensure Squeak5 tests package is loaded in Squeak5' id 'abde1bd6-a8d6-45fc-a922-bcf63ec38f03' date '27 February 2016' time '1:47:23.046532 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.13' message 'Forked Grease-Tests-Pharo-Core into Grease-Tests-Squeak5-Core' id '3a01ebbc-8859-45db-ae5a-e5de8073d3a4' date '27 February 2016' time '1:40:18.726436 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.12' message 'added Pharo-Tests to Squeak5 load' id 'ffe11ade-e4f1-496d-ae59-74543cfad134' date '27 February 2016' time '1:21:56.832518 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.11' message 'added pharo5 platform to baseline' id '5c0332e9-ef4c-43cd-9066-7c9fe9ed6506' date '27 February 2016' time '12:12:12.067693 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.10' message 'added squeak 5 platform' id '18f9d568-869f-4550-804a-b0ba101f33f3' date '13 December 2015' time '8:36:25.150207 pm' author 'JohanBrichau' ancestors ((id 'af9364dd-14bc-4e5e-9fc7-0abe08732ab2')) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())(name 'BaselineOfGrease-dkh.15' message 'merged by GitFileTree-MergeDriver' id '415af41c-2c3d-40a8-9f75-d9e8de921224' date '26 August 2016' time '2:19:29.551006 pm' author 'dkh' ancestors ((id 'ad7f9331-d83f-4976-bf57-1d1e81111fc6')(id 'abde1bd6-a8d6-45fc-a922-bcf63ec38f03')) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())
(name 'BaselineOfGrease-JohanBrichau.1496564071' message 'Fixed dependency of Grease-Tests-Core on the platform packages for GRDynamicVariableTest' id '6dd3612c-6111-0d00-8806-761908c307d1' date '23 July 2017' time '7:29:11.347398 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.1496564070' message '- Removed pharo1.x and 2.x from the baseline since no longer supported.- Fixed dependency of Grease-Tests-Core on the platform packages for GRDynamicVariableTest' id 'd3220dff-6011-0d00-8805-b8f708c307d1' date '23 July 2017' time '7:16:30.82261 pm' author 'JohanBrichau' ancestors ((name 'BaselineOfGrease-JohanBrichau.1496564069' message 'Updated load snippets [ci skip]
' id '26eaf907-cb05-504d-b251-ce1bcf3132ec' date '4 June 2017' time '10:14:29 am' author 'JohanBrichau' ancestors () stepChildren ())) stepChildren ())) stepChildren ())
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
defaults
default
^ self defaultValue
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
defaults
defaultValue
^ nil
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
accessing
use: anObject during: aBlock

| p oldValue result |
"Proper implementation instead of use 'super value:during:' because that one does not return value, perhaps this should be fixed in DynamicVariable?"
p := Processor activeProcess.
oldValue := p environmentAt: self ifAbsent: [self default].
[
p environmentAt: self put: anObject.
result := aBlock value.
] ensure: [
p environmentAt: self put: oldValue
].
^ result
| p oldValue result |
"Proper implementation instead of use 'super value:during:' because that one does not return value, perhaps this should be fixed in DynamicVariable?"
p := Processor activeProcess.
oldValue := p environmentAt: self.
[
p environmentAt: self put: anObject.
result := aBlock value ]
ensure: [ p environmentAt: self put: oldValue ].
^ result
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"class" : {
"use:during:" : "JohanBrichau 05/25/2017 08:13" },
"default" : "JohanBrichau 07/23/2017 09:48",
"defaultValue" : "JohanBrichau 07/23/2017 09:47",
"use:during:" : "JohanBrichau 07/23/2017 07:39" },
"instance" : {
} }

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
accessing
defaultValue
^ nil
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
accessing
default
^ self class defaultValue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"instance" : { },
"class" : {
"use:during:" : "MaxLeske 5/16/2017 21:54"
}
}
"defaultValue" : "JohanBrichau 7/23/2017 17:55",
"use:during:" : "MaxLeske 5/16/2017 21:54" },
"instance" : {
"default" : "JohanBrichau 7/23/2017 17:56" } }
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
{
"commentStamp" : "MaxLeske 5/16/2017 22:05",
"super" : "DynamicVariable",
"category" : "Grease-Pharo30-Core",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"classinstvars" : [
],
"classvars" : [
],
"commentStamp" : "MaxLeske 5/16/2017 22:05",
"instvars" : [
],
"name" : "GRDynamicVariable",
"type" : "normal"
}
"pools" : [
],
"super" : "DynamicVariable",
"type" : "normal" }
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
{
"name" : "GRPackage"
}
"name" : "GRPackage" }
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
{
"class" : {
"on:converter:" : "pmm 10/30/2010 18:58" },
"instance" : {
"nextPut:" : "pmm 4/10/2010 13:30",
"greaseNext:putAll:startingAt:" : "pmm 12/28/2010 22:12",
"nextPutAll:" : "lr 2/7/2009 12:54",
"initializeOn:converter:" : "pmm 10/30/2010 18:58",
"next" : "pmm 4/10/2010 13:32",
"next:" : "lr 2/7/2009 12:57",
"initializeOn:converter:" : "pmm 10/30/2010 18:58"
},
"class" : {
"on:converter:" : "pmm 10/30/2010 18:58"
}
}
"nextPut:" : "pmm 4/10/2010 13:30",
"nextPutAll:" : "lr 2/7/2009 12:54" } }
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
{
"commentStamp" : "pmm 6/25/2012 20:22",
"super" : "GRCodecStream",
"category" : "Grease-Pharo30-Core",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"classinstvars" : [
],
"classvars" : [
],
"commentStamp" : "pmm 6/25/2012 20:22",
"instvars" : [
"converter"
],
"converter" ],
"name" : "GRPharoConverterCodecStream",
"type" : "normal"
}
"pools" : [
],
"super" : "GRCodecStream",
"type" : "normal" }
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
{
"class" : {
"basicForEncoding:" : "pmm 6/28/2009 15:43",
"codecs" : "pmm 8/16/2010 00:19",
"supportedEncodingNames" : "lr 7/25/2011 19:46",
"supportsEncoding:" : "pmm 6/28/2009 16:43" },
"instance" : {
"converter" : "lr 7/25/2011 19:51",
"decoderFor:" : "lr 2/7/2009 12:52",
"url" : "lr 2/7/2009 12:36",
"encoderFor:" : "jf 9/30/2009 00:46",
"initializeWithName:" : "pmm 8/16/2010 11:52",
"name" : "lr 2/7/2009 10:16"
},
"class" : {
"codecs" : "pmm 8/16/2010 00:19",
"supportsEncoding:" : "pmm 6/28/2009 16:43",
"basicForEncoding:" : "pmm 6/28/2009 15:43",
"supportedEncodingNames" : "lr 7/25/2011 19:46"
}
}
"name" : "lr 2/7/2009 10:16",
"url" : "lr 2/7/2009 12:36" } }
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
{
"commentStamp" : "",
"super" : "GRCodec",
"category" : "Grease-Pharo30-Core",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"classinstvars" : [
],
"classvars" : [
],
"commentStamp" : "",
"instvars" : [
"name",
"urlCodec"
],
"urlCodec" ],
"name" : "GRPharoGenericCodec",
"type" : "normal"
}
"pools" : [
],
"super" : "GRCodec",
"type" : "normal" }
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
{
"class" : {
"basicForEncoding:" : "pmm 8/16/2010 00:36",
"codecs" : "lr 7/25/2011 19:46",
"supportedEncodingNames" : "lr 7/25/2011 19:46",
"supportsEncoding:" : "pmm 8/16/2010 00:36" },
"instance" : {
"decoderFor:" : "pmm 8/16/2010 00:32",
"decode:" : "pmm 8/16/2010 09:20",
"initializeWithName:" : "pmm 8/25/2016 11:00",
"decoderFor:" : "pmm 8/16/2010 00:32",
"encoderFor:" : "pmm 8/16/2010 00:32",
"name" : "pmm 8/16/2010 00:32"
},
"class" : {
"codecs" : "lr 7/25/2011 19:46",
"supportsEncoding:" : "pmm 8/16/2010 00:36",
"basicForEncoding:" : "pmm 8/16/2010 00:36",
"supportedEncodingNames" : "lr 7/25/2011 19:46"
}
}
"initializeWithName:" : "pmm 8/25/2016 11:00",
"name" : "pmm 8/16/2010 00:32" } }
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
{
"commentStamp" : "<historical>",
"super" : "GRNullCodec",
"category" : "Grease-Pharo30-Core",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"classinstvars" : [
],
"classvars" : [
],
"commentStamp" : "<historical>",
"instvars" : [
"name"
],
"name" ],
"name" : "GRPharoLatin1Codec",
"type" : "normal"
}
"pools" : [
],
"super" : "GRNullCodec",
"type" : "normal" }
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"class" : {
},
"instance" : {
"next:" : "lr 7/25/2011 19:50",
"next" : "pmm 8/16/2010 09:16"
},
"class" : { }
}
"next" : "pmm 8/16/2010 09:16",
"next:" : "lr 7/25/2011 19:50" } }
Loading

0 comments on commit c9f536d

Please sign in to comment.