A new version of ShoutTests was added to project The Inbox: http://source.squeak.org/inbox/ShoutTests-ct.34.mcz
==================== Summary ====================
Name: ShoutTests-ct.34 Author: ct Time: 7 April 2021, 5:20:15.847598 pm UUID: a7f39f26-a6fb-f44e-aabb-931714b56ed8 Ancestors: ShoutTests-mt.33
Document a present bug that occurs when styling a method that contains multiple unary selectors after a cascade.
=============== Diff against ShoutTests-mt.33 ===============
Item was added: + ----- Method: SHParserST80Test>>testChainAfterCascade (in category 'tests') ----- + testChainAfterCascade + + | types s | + s := 'x 1 positive; negative not'. + + types := self tokenTypesIn: s. + + self + assert: #(patternUnary number unary cascadeSeparator unary excessCode) + equals: types.!
Hi Christoph --
This also addresses ShoutCore-ct.85 sitting in the inbox.
The code snippet you want Shout to style is
x 1 positive; negative not
I don't see how this is valid Smalltalk code. Even like this
x := 1 positive; negative not
the trailing "not" cannot be compiled. Adding parentheses, it becomes valid:
x := (1 positive; negative) not.
...so can you elaborate on what you wanted to test here? I would expect that Shout's results for invalid Smalltalk code is ... undefined?
Best, Marcel Am 07.04.2021 17:20:24 schrieb commits@source.squeak.org commits@source.squeak.org: A new version of ShoutTests was added to project The Inbox: http://source.squeak.org/inbox/ShoutTests-ct.34.mcz
==================== Summary ====================
Name: ShoutTests-ct.34 Author: ct Time: 7 April 2021, 5:20:15.847598 pm UUID: a7f39f26-a6fb-f44e-aabb-931714b56ed8 Ancestors: ShoutTests-mt.33
Document a present bug that occurs when styling a method that contains multiple unary selectors after a cascade.
=============== Diff against ShoutTests-mt.33 ===============
Item was added: + ----- Method: SHParserST80Test>>testChainAfterCascade (in category 'tests') ----- + testChainAfterCascade + + | types s | + s := 'x 1 positive; negative not'. + + types := self tokenTypesIn: s. + + self + assert: #(patternUnary number unary cascadeSeparator unary excessCode) + equals: types.!
Hi Marcel,
this is indeed not valid Smalltalk code. In the test, I expected the last keyword (#not) to be parsed as #excessCode. At the moment, the Shout treats this syntax as valid syntax which has confused me already too often.
Given the confusion, I should probably rename this test or add a proper comment.
Best,
Christoph
________________________________ Von: Squeak-dev squeak-dev-bounces@lists.squeakfoundation.org im Auftrag von Taeumel, Marcel Gesendet: Donnerstag, 25. November 2021 15:04:57 An: squeak-dev Betreff: Re: [squeak-dev] The Inbox: ShoutTests-ct.34.mcz
Hi Christoph --
This also addresses ShoutCore-ct.85 sitting in the inbox.
The code snippet you want Shout to style is
x 1 positive; negative not
I don't see how this is valid Smalltalk code. Even like this
x := 1 positive; negative not
the trailing "not" cannot be compiled. Adding parentheses, it becomes valid:
x := (1 positive; negative) not.
...so can you elaborate on what you wanted to test here? I would expect that Shout's results for invalid Smalltalk code is ... undefined?
Best, Marcel
Am 07.04.2021 17:20:24 schrieb commits@source.squeak.org commits@source.squeak.org:
A new version of ShoutTests was added to project The Inbox: http://source.squeak.org/inbox/ShoutTests-ct.34.mcz
==================== Summary ====================
Name: ShoutTests-ct.34 Author: ct Time: 7 April 2021, 5:20:15.847598 pm UUID: a7f39f26-a6fb-f44e-aabb-931714b56ed8 Ancestors: ShoutTests-mt.33
Document a present bug that occurs when styling a method that contains multiple unary selectors after a cascade.
=============== Diff against ShoutTests-mt.33 ===============
Item was added: + ----- Method: SHParserST80Test>>testChainAfterCascade (in category 'tests') ----- + testChainAfterCascade + + | types s | + s := 'x 1 positive; negative not'. + + types := self tokenTypesIn: s. + + self + assert: #(patternUnary number unary cascadeSeparator unary excessCode) + equals: types.!
squeak-dev@lists.squeakfoundation.org