smalltalk
/
osmo-st-sip
Archived
1
0
Fork 0

misc: Use separatedBy: for the beauty of reading it, no big win

This commit is contained in:
Holger Hans Peter Freyther 2014-09-05 14:23:05 +02:00
parent e7c75b7dcd
commit f13639d443
2 changed files with 6 additions and 6 deletions

View File

@ -167,10 +167,10 @@ SIPGrammar subclass: SIPParser [
^super challenge => [:nodes |
| d |
d := Dictionary new.
(nodes at: 4) do:
[:each | d at: each second first put: each second third ].
d at: (nodes at: 3) first put: (nodes at: 3) third.
(nodes at: 2) do: [:each |
"Skip the separator for now until we have withoutSeparators"
each isCharacter ifFalse: [
d at: each first put: each third]].
d]
]

View File

@ -529,7 +529,7 @@ PP.PPCompositeParser subclass: SIPGrammar [
challenge [
<category: 'WWW-Authenticate'>
^('Digest' asParser, LWS, self digest_cln, (COMMA, self digest_cln) star) /
^('Digest' asParser trim, (digest_cln separatedBy: COMMA)) /
self other_challenge
]
@ -541,7 +541,7 @@ PP.PPCompositeParser subclass: SIPGrammar [
other_challenge [
<category: 'WWW-Authenticate'>
^self auth_scheme, LWS, self auth_param, (COMMA, self auth_param) star
^self auth_scheme trim, (auth_param separatedBy: COMMA)
]
realm [