[squeak-dev] The Trunk: Regex-Core-ct.80.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Oct 12 08:26:25 UTC 2022


Christoph Thiede uploaded a new version of Regex-Core to project The Trunk:
http://source.squeak.org/trunk/Regex-Core-ct.80.mcz

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

Name: Regex-Core-ct.80
Author: ct
Time: 12 October 2022, 10:26:25.906375 am
UUID: ef17e2f9-69d8-ed49-871b-0e82767b7f0d
Ancestors: Regex-Core-ct.79

Fixes a widespread typo in an argument name.

=============== Diff against Regex-Core-ct.79 ===============

Item was changed:
  ----- Method: RxMatcher>>matchAgainstLookahead:positive:nextLink: (in category 'matching') -----
+ matchAgainstLookahead: lookahead positive: positive nextLink: anRxmLink
- matchAgainstLookahead: lookahead positive: positive nextLink: anRmxLink
  
  	| position result |
  	position := stream position.
  	result := lookahead matchAgainst: self.
  	stream position: position.
  	^ result = positive and: [
+ 		anRxmLink matchAgainst: self]!
- 		anRmxLink matchAgainst: self]!

Item was changed:
  ----- Method: RxMatcher>>matchAgainstLookbehind:positive:nextLink: (in category 'matching') -----
+ matchAgainstLookbehind: lookbehind positive: positive nextLink: anRxmLink
- matchAgainstLookbehind: lookbehind positive: positive nextLink: anRmxLink
  
  	| position matchesLookbehind |
  	position := stream position.
  	matchesLookbehind := (position to: 0 by: -1)
  		anySatisfy: [:index |
  			stream position: index.
  			(lookbehind matchAgainst: self)
  				and: [stream position = position]].
  	stream position: position.
  	matchesLookbehind = positive
  		ifFalse: [^ false].
+ 	^ anRxmLink matchAgainst: self!
- 	^ anRmxLink matchAgainst: self!

Item was changed:
  ----- Method: RxMatcher>>matchAgainstMarkerAt:nextLink: (in category 'matching') -----
+ matchAgainstMarkerAt: index nextLink: anRxmLink
- matchAgainstMarkerAt: index nextLink: anRmxLink
  
  	| position |
  	position := stream position.
+ 	(anRxmLink matchAgainst: self) ifFalse: [ ^false ].
- 	(anRmxLink matchAgainst: self) ifFalse: [ ^false ].
  	index <= 2 
  		ifTrue: [ markerPositions at: index put: position ]
  		ifFalse: [ (markerPositions at: index) addFirst: position ].
  	^true!

Item was changed:
  ----- Method: RxMatcher>>matchAgainstPredicate:nextLink: (in category 'matching') -----
+ matchAgainstPredicate: aBlock nextLink: anRxmLink
- matchAgainstPredicate: aBlock nextLink: anRmxLink
  
  	| next position |
  	next := stream next ifNil: [ ^false ].
  	position := stream position - 1.
  	(aBlock value: next) ifTrue: [
+ 		(anRxmLink matchAgainst: self) ifTrue: [ ^true ] ].
- 		(anRmxLink matchAgainst: self) ifTrue: [ ^true ] ].
  	stream position: position.
  	^false!

Item was changed:
  ----- Method: RxMatcher>>matchCaseInsensitiveAgainstStream:nextLink: (in category 'matching') -----
+ matchCaseInsensitiveAgainstStream: aStream nextLink: anRxmLink
- matchCaseInsensitiveAgainstStream: aStream nextLink: anRmxLink
  
  	| next nextSample position |
  	position := stream position.
  	"The order of the stream reads is important. When aStream runs out of characters, we must not consume any character from stream, or else the next position will be skipped in stream."
  	[ (nextSample := aStream next) == nil or: [ (next := stream next) == nil ] ] whileFalse: [
  		(nextSample sameAs: next) ifFalse: [
  			stream position: position.
  			^false ] ].
+ 	(nextSample == nil and: [ anRxmLink matchAgainst: self ]) ifTrue: [ ^true ].
- 	(nextSample == nil and: [ anRmxLink matchAgainst: self ]) ifTrue: [ ^true ].
  	stream position: position.
  	^false!

Item was changed:
  ----- Method: RxMatcher>>matchCaseSensitiveAgainstStream:nextLink: (in category 'matching') -----
+ matchCaseSensitiveAgainstStream: aStream nextLink: anRxmLink
- matchCaseSensitiveAgainstStream: aStream nextLink: anRmxLink
  
  	| next nextSample position |
  	position := stream position.
  	"The order of the stream reads is important. When aStream runs out of characters, we must not consume any character from stream, or else the next position will be skipped in stream."
  	[ (nextSample := aStream next) == nil or: [ (next := stream next) == nil ] ] whileFalse: [
  		nextSample == next ifFalse: [
  			stream position: position.
  			^false ] ].
+ 	(nextSample == nil and: [ anRxmLink matchAgainst: self ]) ifTrue: [ ^true ].
- 	(nextSample == nil and: [ anRmxLink matchAgainst: self ]) ifTrue: [ ^true ].
  	stream position: position.
  	^false!



More information about the Squeak-dev mailing list