Differences From Artifact [f1e270d342]:
- File
src/OFOptionsParser.m
— part of check-in
[4af49a13c3]
at
2017-05-07 20:10:13
on branch trunk
— Small code style change
Casts are now written like types in variable declarations. (user: js, size: 6488) [annotate] [blame] [check-ins using] [more...]
To Artifact [77a19bfe68]:
- File src/OFOptionsParser.m — part of check-in [2de9660312] at 2017-09-28 23:02:23 on branch trunk — Enable -Wnullable-to-nonnull-conversion and adjust (user: js, size: 6551) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
103 104 105 106 107 108 109 | if (iter->longOption != nil) { @try { iter2->longOption = [iter->longOption copy]; if ([_longOptions objectForKey: | | > > | | 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 | if (iter->longOption != nil) { @try { iter2->longOption = [iter->longOption copy]; if ([_longOptions objectForKey: (OFString *)iter2->longOption] != NULL) @throw [OFInvalidArgumentException exception]; [_longOptions setObject: iter2 forKey: (OFString *) iter2->longOption]; } @catch (id e) { /* * Make sure we are in a consistent * state where dealloc works. */ [iter2->longOption release]; |
︙ | ︙ | |||
205 206 207 208 209 210 211 | pos = [argument length]; _lastLongOption = [[argument substringWithRange: of_range(2, pos - 2)] copy]; objc_autoreleasePoolPop(pool); | | > | 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 | pos = [argument length]; _lastLongOption = [[argument substringWithRange: of_range(2, pos - 2)] copy]; objc_autoreleasePoolPop(pool); option = [_longOptions objectForKey: (OFString *)_lastLongOption]; if (option == NULL) return '?'; if (option->hasArgument == 1 && _argument == nil) return ':'; if (option->hasArgument == 0 && _argument != nil) return '='; |
︙ | ︙ |