Comcast / mamba

Mamba is a Swift iOS, tvOS and macOS framework to parse, validate and write HTTP Live Streaming (HLS) data.
Apache License 2.0
178 stars 39 forks source link

FailableStringLiteralConvertible should be a little more specific in it's initializer. #14

Closed dcoufal closed 5 years ago

dcoufal commented 6 years ago

Description

A number of common types (Int, Float, etc) have the FailableStringLiteralConvertible interface.

public protocol FailableStringLiteralConvertible {
    init?(string: String)
}

This is public since users might want to create custom HLS parsers for their custom tags.

But, it's not clear that these belong to mamba.

Rename the initializer to be more specific to mamba, or at least make it clearer that this is custom and you shouldn't be using it if you don't recognize it.

My first thought is:

public protocol FailableStringLiteralConvertible {
    init?(withFailableString: String)
}

Tasks

dcoufal commented 5 years ago

Fixed