Introduce VMOPTIONLEN that can offset the extra '-' in the You can view, comment on, or merge this pull request online at:https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/231 Commit Summary
File ChangesPatch Links:
— |
@krono commented on this pull request. In platforms/iOS/vm/OSX/sqSqueakOSXApplication.m: > @@ -166,7 +168,7 @@ - (int) parseArgument: (NSString *) argData peek: (char *) peek /* Options with no arguments */ NS_DURING; - if ([argData compare: VMOPTIONOBJ("psn_") options: NSLiteralSearch range: NSMakeRange(0,5)] == NSOrderedSame) { + if ([argData compare: VMOPTIONOBJ("psn_") options: NSLiteralSearch range: NSMakeRange(0,VMOPTIONLEN(5))] == NSOrderedSame) { Side comment: using — |
In reply to this post by David T Lewis
@zecke commented on this pull request. In platforms/iOS/vm/OSX/sqSqueakOSXApplication.m: > @@ -166,7 +168,7 @@ - (int) parseArgument: (NSString *) argData peek: (char *) peek /* Options with no arguments */ NS_DURING; - if ([argData compare: VMOPTIONOBJ("psn_") options: NSLiteralSearch range: NSMakeRange(0,5)] == NSOrderedSame) { + if ([argData compare: VMOPTIONOBJ("psn_") options: NSLiteralSearch range: NSMakeRange(0,VMOPTIONLEN(5))] == NSOrderedSame) { Good point. OSX doesn't care about the number of dashes we have. I don't like the code. We should strip the dashes before parsing the arguments but that would have been a bigger change and outside the timebox I had. :( — |
In reply to this post by David T Lewis
@krono commented on this pull request. In platforms/iOS/vm/OSX/sqSqueakOSXApplication.m: > @@ -166,7 +168,7 @@ - (int) parseArgument: (NSString *) argData peek: (char *) peek /* Options with no arguments */ NS_DURING; - if ([argData compare: VMOPTIONOBJ("psn_") options: NSLiteralSearch range: NSMakeRange(0,5)] == NSOrderedSame) { + if ([argData compare: VMOPTIONOBJ("psn_") options: NSLiteralSearch range: NSMakeRange(0,VMOPTIONLEN(5))] == NSOrderedSame) { No problem, just a side comment to not forget — |
In reply to this post by David T Lewis
Agree, we can do better, but this is good enough, we'll see better later. — |
In reply to this post by David T Lewis
Merged #231. — |
Free forum by Nabble | Edit this page |