Skip to content
Snippets Groups Projects
Commit ccdc8e7b authored by Dariusz Rybicki's avatar Dariusz Rybicki
Browse files

Conform FactType to ExpressibleByIntegerLiteral

parent 0c4c6b0f
No related branches found
No related tags found
2 merge requests!102Release 1.0.0,!71Fact improvements & helpers
...@@ -28,6 +28,12 @@ extension FactType: RawRepresentable { ...@@ -28,6 +28,12 @@ extension FactType: RawRepresentable {
} }
} }
extension FactType: ExpressibleByIntegerLiteral {
public init(integerLiteral value: IntegerLiteralType) {
self.init(rawValue: value)
}
}
extension FactType: Codable { extension FactType: Codable {
public init(from decoder: Decoder) throws { public init(from decoder: Decoder) throws {
let container = try decoder.singleValueContainer() let container = try decoder.singleValueContainer()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment