This repository was archived by the owner on Nov 16, 2020. It is now read-only.
Update DateFormat.swift#37
Open
MihaelIsaev wants to merge 4 commits intovapor:masterfrom
MihaelIsaev:patch-1
Open
Update DateFormat.swift#37MihaelIsaev wants to merge 4 commits intovapor:masterfrom MihaelIsaev:patch-1
MihaelIsaev wants to merge 4 commits intovapor:masterfrom
MihaelIsaev:patch-1
Conversation
Add ability to set locale as third parameter
Change error text
Also add ability to set time zone
tanner0101
reviewed
Sep 17, 2018
Member
tanner0101
left a comment
There was a problem hiding this comment.
LGTM, just some small changes.
| case 1, 2: break | ||
| default: throw tag.error(reason: "Invalid parameter count: \(tag.parameters.count). 1 or 2 required.") | ||
| case 1, 2, 3, 4: break | ||
| default: throw tag.error(reason: "Invalid parameter count: \(tag.parameters.count). 1 or 2 or 3 or 4 required.") |
Member
There was a problem hiding this comment.
Would be a bit less awkward to read as:
1, 2, 3, or 4 required
| switch tag.parameters.count { | ||
| case 1, 2: break | ||
| default: throw tag.error(reason: "Invalid parameter count: \(tag.parameters.count). 1 or 2 required.") | ||
| case 1, 2, 3, 4: break |
Member
There was a problem hiding this comment.
This could be better expressed as 1...4
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add ability to set locale as third parameter