Skip to content

Commit

Permalink
Remove irrelevant todos
Browse files Browse the repository at this point in the history
  • Loading branch information
Joannis committed Oct 28, 2018
1 parent 9e8893d commit a42fc9f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
1 change: 1 addition & 0 deletions Sources/BSON/Document/Document+Cache.swift
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,7 @@ extension Document {
return nil
}

// Omit the null terminator as we don't use/need that in Swift
return self.storage.getString(at: offset &+ 4, length: numericCast(length) - 1)
case .binary:
guard let length = self.storage.getInteger(at: offset, endianness: .little, as: Int32.self) else {
Expand Down
2 changes: 0 additions & 2 deletions Sources/BSON/Document/Document+Mutations.swift
Original file line number Diff line number Diff line change
Expand Up @@ -155,9 +155,7 @@ extension Document {
storage.write(string: regex.options)
storage.write(integer: 0x00, endianness: .little, as: UInt8.self)
// 0x0C is deprecated (DBPointer)
// TODO: JavascriptCode (0x0D)
// 0x0E is deprecated (Symbol)
// TODO: JavascriptCode With Scope (0x0F)
case let int as Int32: // 0x10
prepareWritingPrimitive(.int32, bodyLength: 4, existingDimensions: dimensions, key: key)
storage.write(integer: int, endianness: .little)
Expand Down
1 change: 0 additions & 1 deletion Sources/BSON/Types/Primitives.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import Foundation

public protocol Primitive: Codable, PrimitiveConvertible {}

// TODO: Investigate if this protocol is needed
internal protocol BSONDataType: Primitive {
var primitive: Primitive { get }
init(primitive: Primitive?) throws
Expand Down

0 comments on commit a42fc9f

Please sign in to comment.