1
1
mirror of https://github.com/qvacua/vimr.git synced 2024-11-24 11:37:32 +03:00

GH-666 Add comments

This commit is contained in:
Tae Won Ha 2018-09-02 17:39:23 +02:00
parent 9a5ac3f631
commit 10d475dbaa

View File

@ -1,12 +1,13 @@
//
// Created by Tae Won Ha on 19.08.18.
// Copyright (c) 2018 Tae Won Ha. All rights reserved.
//
/**
* Tae Won Ha - http://taewon.de - @hataewon
* See LICENSE
*/
import Foundation
extension Array where Element: Hashable {
// From https://stackoverflow.com/a/46354989/9850227
func uniqued() -> [Element] {
var seen = Set<Element>()
return self.filter { seen.insert($0).inserted }