Re: [swift-users] Synthesized Equatable Bug?

2018-01-15 Thread Jon Shier via swift-users
griboz...@gmail.com> wrote: > > On Mon, Jan 15, 2018 at 2:30 PM, Jon Shier via swift-users > <swift-users@swift.org> wrote: >> This is pretty straightforward code, so am I missing something here? > > Your '<' function does not define a valid strict total orde

[swift-users] Synthesized Equatable Bug?

2018-01-15 Thread Jon Shier via swift-users
Swifters: Take this simple Point type: struct Point: Hashable { let x: Int let y: Int init(_ x: Int, _ y: Int) { self.x = x self.y = y } } Using the latest Swift 4.1 snapshot, the Hashable conformance is generated for me. Adding Comparable conformance

Re: [swift-users] "Month 13 is out of bounds"

2018-01-02 Thread Jon Shier via swift-users
This is a known issue for High Sierra, and is output from a variety of apps during normal system usage. Just search your Console logs and you’ll see many instances. Unfortunately I’m not sure how to ignore the output in Xcode, but you don’t need to care about it. Who knows if it’ll be

Re: [swift-users] I ve found a serious Bug in JSONEncoder (SR-6131) and would like to fix it.

2017-12-18 Thread Jon Shier via swift-users
I’m pretty sure JSON isn’t localized, so this isn’t a bug. Using anything but a . as a decimal separator isn’t valid JSON. Jon > On Dec 18, 2017, at 11:51 AM, Benoit Pereira da silva via swift-users > wrote: > > Dear all > > I've found a serious Bug in JSONEncoder

[swift-users] Refining generics in classes

2017-11-15 Thread Jon Shier via swift-users
Swift Users: I have a generics use case which has somewhat stumped me. I have two related protocols, JSONDecodable and CompressedDecodable, and CompressedDecodable inherits from JSONDecodable (though that relationship isn’t strictly necessary). I also have a generic function

Re: [swift-users] Parsing Decimal values from JSON

2017-10-31 Thread Jon Shier via swift-users
The appropriate solution here would be for Swift to have its own native JSON parser that allows direct decoding into generic types without the intermediary of JSONSerialization. For whatever reason there seems to be resistance to this from the Swift team, but until we have that ability,

[swift-users] Swift Version Conditionals in Objective-C?

2017-09-22 Thread Jon Shier via swift-users
In moving a hybrid project from Swift 3 to 4, I’ve run into some issues from my Objective-C code. I’ve been able to conditionalize my Swift code for both versions pretty easily, but there are APIs imported from Objective-C that need to change definition for Swift 4. Is there anyway, in

Re: [swift-users] Swift 4 "Cannot use mutating member on immutable value: 'self' is immutable"

2017-09-17 Thread Jon Shier via swift-users
Yes, it seems to fly in the face of protocols as they exist in Swift at the moment. Given the inability of protocols to guarantee performance characteristics, breaking conformant types like this seems like a bad way to try and fulfill a separate axis of concern. Wouldn’t a better idea

Re: [swift-users] Swift 4 "Cannot use mutating member on immutable value: 'self' is immutable"

2017-09-14 Thread Jon Shier via swift-users
d have it, but in any case, this looks like a bad error message at least. Jon > On Sep 14, 2017, at 11:05 AM, Jon Shier via swift-users > <swift-users@swift.org> wrote: > > This seems oddly similar to https://bugs.swift.org/browse/SR-5659 > <https://bugs.swift.o

Re: [swift-users] Swift 4 "Cannot use mutating member on immutable value: 'self' is immutable"

2017-09-14 Thread Jon Shier via swift-users
sort of Swift bug here. Jon > On Sep 14, 2017, at 10:48 AM, Jon Shier via swift-users > <swift-users@swift.org> wrote: > > It also doesn’t explain why removeFirst would work but popFirst > doesn’t. The mutation to the underlying array should be the same, the only &g

Re: [swift-users] Swift 4 "Cannot use mutating member on immutable value: 'self' is immutable"

2017-09-14 Thread Jon Shier via swift-users
It also doesn’t explain why removeFirst would work but popFirst doesn’t. The mutation to the underlying array should be the same, the only different is that one returns the element optionally. It also doesn’t explain why popFirst doesn’t show up I the autocomplete but compiles anyway.

Re: [swift-users] Swift 4 "Cannot use mutating member on immutable value: 'self' is immutable"

2017-09-13 Thread Jon Shier via swift-users
I think there’s something strange with popFirst. It doesn’t show up in the autocomplete in Xcode, but it compiles, and popLast doesn’t throw the same error. removeFirst doesn’t either, though it’s unsafe. Weird. Jon > On Sep 13, 2017, at 9:47 PM, Zhao Xin via swift-users

[swift-users] No Generic Decoders?

2017-09-02 Thread Jon Shier via swift-users
Swift Users: I’ve been exploring the creation of Decodable response serializers for Alamofire. However, there doesn’t actually seem to be any way to express the notion of a generic decoder. The Decoder protocol itself doesn’t require a `decode(type:from:)` method, and neither

Re: [swift-users] Still can't derive from a generic class

2017-08-29 Thread Jon Shier via swift-users
This works fine for me in a playground in the latest Xcode 9 beta: class Test { } class Base { } class Sub: Base { } let sub = Sub() Jon > On Aug 29, 2017, at 1:04 PM, Joanna Carter via swift-users > wrote: > > Hi > > I would have hoped by now that it should be

Re: [swift-users] What is up with names not being Strings any more in Swift 4?

2017-07-18 Thread Jon Shier via swift-users
I'd agree with that. Fortunately there are tools out there that can parse such things and generate the constants for us already. Waiting for Xcode to implement such common sense quality of life improvements probably won't end. I'll file bugs in the meantime though. Jon > On Jul 18, 2017, at

Re: [swift-users] Printing Enums?

2017-07-17 Thread Jon Shier via swift-users
Certain Objective-C enums don’t print a useful debug description. I usually work around this by implementing CustomStringConvertible (or the debug version) for the type myself. You probably want to file a bug with Apple. Jon > On Jul 17, 2017, at 6:15 PM, Michael Rogers via

Re: [swift-users] What is up with names not being Strings any more in Swift 4?

2017-07-17 Thread Jon Shier via swift-users
Making them an extension on String makes them visible everywhere String is used, unless you limit the visibility in some way, which impacts the performance of autocomplete and fills it with random constants. Like I said, part of the reason for this is to separate the constants. Jon

Re: [swift-users] What is up with names not being Strings any more in Swift 4?

2017-07-17 Thread Jon Shier via swift-users
Like Notification.Name, I believe those types are supposed to help you namespace your string constants when you access them. I’d recommend using a code gen tool to generate them from your image assets, like: extension NSImage.Name { static let customImage =

Re: [swift-users] extension on UISlider breaks interface builder??

2017-07-14 Thread Jon Shier via swift-users
In my experience, yes, it started with Xcode 8, though I don’t specifically remember extending types I was using in IB in Xcode 7. Jon > On Jul 14, 2017, at 11:54 PM, David Baraff <davidbar...@gmail.com> wrote: > >> >> On Jul 14, 2017, at 8:53 PM, J

Re: [swift-users] Swift 4 thread sanitizer more sensitive?

2017-07-06 Thread Jon Shier via swift-users
sues/2189 but it seems to be a >> legit issue. Thanks! >> >> >> >> Jon >> >>>> On Jun 26, 2017, at 1:54 PM, Joe Groff <jgr...@apple.com> wrote: >>>> >>>> >>>>> On Jun 26, 2017, at 10:33 AM, Joe Groff via swif

Re: [swift-users] Disable "indexing while building" in Xcode9 (unknown argument: `-index-store-path`)

2017-07-04 Thread Jon Shier via swift-users
ct offering to whatever level of >>> privacy they desire. And, the iPad Playgrounds Application is >>> Apple-proprietary as well. >>> >>> What components/Swift features are you concerned about? >>> >>> Just asking. >>> >>> Jona

Re: [swift-users] Disable "indexing while building" in Xcode9 (unknown argument: `-index-store-path`)

2017-07-04 Thread Jon Shier via swift-users
Xcode 9 fixes my biggest complaint about Xcode, which was the text editor. The new one, based off the one used in the Playgrounds iPad app, is far better in pretty much every way than the old one. It’s still missing features (which should be added by release) but I use it as much as I

Re: [swift-users] Swift 4 thread sanitizer more sensitive?

2017-07-02 Thread Jon Shier via swift-users
4 PM, Joe Groff <jgr...@apple.com> wrote: > > >> On Jun 26, 2017, at 10:33 AM, Joe Groff via swift-users >> <swift-users@swift.org> wrote: >> >> >>> On Jun 25, 2017, at 3:56 PM, Jon Shier via swift-users >>> <swift-users@swift

Re: [swift-users] Swift Documentation question

2017-07-01 Thread Jon Shier via swift-users
swiftdoc.org should be integrated into swift.org and be kept officially up to date. Unfortunately it doesn’t have Swift 4 coverage yet, which is a shame, as I like that documentation format more than Apple’s official one. Jon > On Jul 1,

[swift-users] Swift 4 thread sanitizer more sensitive?

2017-06-25 Thread Jon Shier via swift-users
Running Alamofire through the thread sanitizer and the thread sanitizer finds issues in Swift 4 mode but not Swift 3.2. Does Swift 4 add additional threading instrumentation that you don’t get under other versions? Or is there some other runtime difference that explains it? Jon Shier

Re: [swift-users] intercept fatalError() or other termination messages from swift?

2017-06-23 Thread Jon Shier via swift-users
Crashlytics can pick up these strings just fine. I thought they were part of the full crash dump. > On Jun 24, 2017, at 12:13 AM, David Baraff via swift-users > wrote: > > I realize this is slightly centric to iOS, but it irks me that both Apple’s > crash report logs

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-23 Thread Jon Shier via swift-users
gh might not make it in the upcoming betas, should > be fairly simple introduce. Would this solve that use case? > > We’re also working on improving NSISO8601DateFormatter. I don’t think I saw > it in any of your emails — what specific use case are you looking for that it > doe

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-23 Thread Jon Shier via swift-users
Your gist is extremely interesting to me. I had tried something similar with Argo’s existing JSON enum, but was somewhat stymied by trying to decode it from an unkeyed container. I suppose I still don’t have a good grasp on all of the existing container types. Jon > On Jun 23,

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-23 Thread Jon Shier via swift-users
will never be fixed. Jon > On Jun 23, 2017, at 4:34 AM, David Hart <da...@hartbit.com> wrote: > > > On 23 Jun 2017, at 03:45, Jon Shier via swift-users <swift-users@swift.org > <mailto:swift-users@swift.org>> wrote: > >> I’m sorry, are you complaini

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-22 Thread Jon Shier via swift-users
not actually intended to handle all JSON you should probably call it something else. Jon > On Jun 22, 2017, at 9:42 PM, Greg Parker <gpar...@apple.com> wrote: > > >> On Jun 22, 2017, at 6:00 PM, Jon Shier via swift-users >> <swift-users@swift.org <mai

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-22 Thread Jon Shier via swift-users
and a statement of intent of > how we believe this API is best used. > > - Tony > >> On Jun 18, 2017, at 7:23 PM, Jon Shier via swift-users >> <swift-users@swift.org <mailto:swift-users@swift.org>> wrote: >> >> Given that, per his description, “m

Re: [swift-users] Extensions on Typealiased Existential Protocols

2017-06-19 Thread Jon Shier via swift-users
What I usually do here is: typealias CProtocol = A & B protocol C: CProtocol { } // or just A & B directly, I think extension C {} So it’s a bit silly to me. Jon > On Jun 19, 2017, at 3:44 PM, Slava Pestov via swift-users > wrote: > > Hi Steven, > >> On Jun 19,

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-18 Thread Jon Shier via swift-users
oder() > > do { > let user = try decoder.decode(User.self, from: data) > print(user) > } > catch { > print("error:\(error)") > } > > Reference: > > https://developer.apple.com/videos/play/wwdc2017/212/ > <https://developer.apple.com/v

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-18 Thread Jon Shier via swift-users
The more I use Codable, the less suited to networking it becomes. In reading a variety of blog posts about implementing custom Decodable support from JSON, I kept running across the same pattern. Basically, users had started implementing their own decoding protocols which wrap Decodable

Re: [swift-users] Decode a JSON object of unknown format into a Dictionary with Decodable in Swift 4

2017-06-18 Thread Jon Shier via swift-users
Your issue here is Any, which will likely never be Decodable. You’ll need an actual type to contain the raw JSON. Hilariously, I have to wonder if Argo’s JSON enum could be made Decodable, as it can represent every valid JSON type typically contained in the Any returned by

Re: [swift-users] Linux equivalent of macOS/iOS run loop, aka libdispatch/Dispatch on Linux

2017-04-05 Thread Jon Shier via swift-users
Dispatch equivalent should be dispatchMain(), unless that’s not available on Linux for some reason. Jon > On Apr 5, 2017, at 4:28 PM, Rick Mann via swift-users > wrote: > > I've got Swift and libdispatch installed and linking under Ubuntu 16.04, but > I'm not sure

Re: [swift-users] Swift 3.1 String(

2017-04-05 Thread Jon Shier via swift-users
This was something that sounded like a good change but is extremely annoying in use. Once I get time I’m going to try writing an extension on Optional that generates a logDescription property so I don’t have to use that awful String(describing:) API. Jon Shier > On Apr 5, 2017, at

Re: [swift-users] Improving compilation times?

2017-03-28 Thread Jon Shier via swift-users
That setting breaks incremental compilation, so you're getting clean build speed at the expense of incremental builds. Jon > On Mar 28, 2017, at 7:35 AM, Bartłomiej Nowak via swift-users > wrote: > > I’ve had the same issue and adding a user-defined setting >

Re: [swift-users] Improving compilation times?

2017-03-22 Thread Jon Shier via swift-users
It’s a rather severe regression from Objective-C, where equivalent amounts of code could be compiled in 2 - 3 minutes. I think we all understand why swiftc is so much slower than clang, but it’s concerning that, with all of the talk of new features or changes for Swift 4, there’s no

Re: [swift-users] [swift-evolution] Plan to move swift-evolution and swift-users mailing lists to Discourse

2017-03-20 Thread Jon Shier via swift-users
Sorry, didn’t see the other threads about this. Sooner is better but I’m glad to know it’s at least planned. Jon > On Mar 20, 2017, at 12:39 PM, Jon Shier wrote: > > So when is this transition happening? The sooner the better, as Mail > can’t really handle threads

Re: [swift-users] [swift-evolution] Plan to move swift-evolution and swift-users mailing lists to Discourse

2017-03-20 Thread Jon Shier via swift-users
So when is this transition happening? The sooner the better, as Mail can’t really handle threads with large messages, like the recent evolution threads about Foundation serialization and decoding. It just stops rendering messages. Discourse would help a lot for these sorts of

Re: [swift-users] Confusing Error localizedDescription output

2017-02-28 Thread Jon Shier via swift-users
, which >>> means it's not a customization point. You need to actually conform to >>> LocalizedError and provide a valid 'errorDescription' instead. >>> >>> (It's too bad that your second test works at all, since MyError doesn't >>> conform t

Re: [swift-users] Confusing Error localizedDescription output

2017-02-28 Thread Jon Shier via swift-users
l Errors can be bridged to NSError.) >> >> If you're interested, you can find more information about the design in its >> proposal, SE-0112 >> <https://github.com/apple/swift-evolution/blob/master/proposals/0112-nserror-bridging.md>. >> >> Hope thi

Re: [swift-users] Confusing Error localizedDescription output

2017-02-28 Thread Jon Shier via swift-users
gt;. > > Hope this helps, > Jordan > > >> On Feb 28, 2017, at 12:54, Jon Shier via swift-users <swift-users@swift.org >> <mailto:swift-users@swift.org>> wrote: >> >> Swifters: >> I have a custom error enum: >> >>

[swift-users] Confusing Error localizedDescription output

2017-02-28 Thread Jon Shier via swift-users
Swifters: I have a custom error enum: enum MyError: Error { case network(error: Error) case json(error: Error) case value(error: Error) var localizedDescription: String { switch self { case let .network(error): return error.localizedDescription

Re: [swift-users] The case of broken polymorphism or "Cannot convert value of type to expected argument type"?

2017-02-20 Thread Jon Shier via swift-users
Also possibly related is the covariance in protocol requirements. The following example doesn’t compile without casting the arrays or single values to the exact types required in the protocols, despite being covariant through protocol conformance or subclass. protocol HasViews { var

Re: [swift-users] ambiguous minus operator

2017-02-16 Thread Jon Shier via swift-users
I’ve had good luck with being able to click the candidates in cases like this so Xcode will navigate to those bits of code. However, in this case I think the issue is that the candidates weren’t from user code but from the standard library, which Xcode has all sorts of issues navigating

Re: [swift-users] Rational behind having 2 different behaviors for flatMap?

2017-02-13 Thread Jon Shier via swift-users
According to the compiler, the closure argument for flatMap is not optional or defaulted, so it’s always required. I think it should default to { $0 }, but whatever. Jon > On Feb 13, 2017, at 8:26 PM, Saagar Jha via swift-users > wrote: > > flatMap was designed to

Re: [swift-users] Crash with swift_weakLoadStrong in the stack

2017-02-13 Thread Jon Shier via swift-users
k references I can see, except perhaps the implicit ones from NotificationCenter. Badly resymbolicated log? Is that even possible? Jon > On Feb 13, 2017, at 6:52 PM, Greg Parker <gpar...@apple.com> wrote: > >> >> On Feb 13, 2017, at 12:18 PM, Jon Shier via swift-user

Re: [swift-users] Debugger woes

2017-01-31 Thread Jon Shier via swift-users
This is pretty normal debugger behavior for me. Issues with printing variables clearly in scope, using types or operators from other modules, and poor performance happen every time I try to debug Swift under Xcode. I’ve never found anything that works reliably. Jon > On Jan 31,

Re: [swift-users] Documentation for Linux Development

2016-12-18 Thread Jon Shier via swift-users
http://swiftdoc.org is a good online reference, though not always completely up to date (just mostly). Jon > On Dec 18, 2016, at 9:44 PM, Steven Harms via swift-users > wrote: > > Hi, > > I've been playing with Swift in Linux contexts, but I

Re: [swift-users] Bool to Int

2016-11-20 Thread Jon Shier via swift-users
Except in that case true isn’t a Bool but an NSNumber, which is why you can initialize an Int from it. It seems trivially easy to add an Int extension to do what you want though. Jon > On Nov 20, 2016, at 10:48 PM, Rick Mann via swift-users > wrote: > > It seems I

Re: [swift-users] Reducing Array to OptionSet

2016-11-03 Thread Jon Shier via swift-users
;>>> private let _rawValue: Int >>>> >>>> private enum StringEnum: String { case one, two, three } >>>> public init(strings: [String]) { >>>> var set = MyOptionSet() >>>> strings.flatMap({ StringEn

Re: [swift-users] Reducing Array to OptionSet

2016-11-03 Thread Jon Shier via swift-users
ase one, two, three } >>> public init(strings: [String]) { >>> var set = MyOptionSet() >>> strings.flatMap({ StringEnum(rawValue: $0) }) >>> .flatMap({ MyOptionSet(rawValue: 1 << $0.hashValue) }) >>> .forEach {

Re: [swift-users] Reducing Array to OptionSet

2016-11-03 Thread Jon Shier via swift-users
> } > > let stringArray: [String] = ["one", "three"] > let stringOptions = MyOptionSet(strings: stringArray) > stringOptions.rawValue > >> On Nov 3, 2016, at 7:09 PM, Jon Shier via swift-users <swift-users@swift.org >> <mailto:swift

[swift-users] Reducing Array to OptionSet

2016-11-03 Thread Jon Shier via swift-users
Swifters: I’m dealing with a JSON API where sets of options are returned as arrays of strings. Representing these as OptionSets seems ideal. I can decode the arrays of strings into an array of individual OptionSet values, but I’ve run into a dead end when trying generically reduce the

Re: [swift-users] Segmentation fault: 11 after updating codebase to Swift 3.0

2016-10-24 Thread Jon Shier via swift-users
If you haven’t tried it yet, perhaps commenting out the content of the Row file will prevent the crash and let the build fail with normal errors? Then you can comment in parts of the file and see where the crash is occurring. As to the overall stability of the compiler, stuff

Re: [swift-users] Segmentation fault: 11 after updating codebase to Swift 3.0

2016-10-21 Thread Jon Shier via swift-users
With Swift 3 I’ve found these crashes to be indicative of an underlying source issue rather than something random in the compiler. When you get the crash, can you get the backtrace in the Xcode build log? Sometimes that has clues about what it was doing when it crashed. A lot of the time when

[swift-users] Generic type for a generic type?

2016-09-20 Thread Jon Shier via swift-users
Swifters: I’m running into a type inference problem when attempting to pass a generic type which is generic to a generic type to a function which expects a generic type. I’ll explain: I have a function: func add(observer: Observer) where Observer.Procedure == Procedure Which I’m

Re: [swift-users] Issues with UITableView*

2016-09-12 Thread Jon Shier via swift-users
UITableView already has the notion of “selected rows” built in, so I’d suggest starting there. Jon > On Sep 12, 2016, at 6:41 PM, Ole Begemann via swift-users > wrote: > > > Hmm - interesting to know. Unfortunately, if I do that, then I get > > NO indication of

Re: [swift-users] Swift 3 (Xcode 8 GM) issue with @escaping

2016-09-07 Thread Jon Shier via swift-users
Perhaps relatedly, it no longer seems possible to mark typealiased closures as @escaping. That was quite handy when you know that closures will always be used asynchronously. Jon > On Sep 7, 2016, at 6:15 PM, Shawn Erickson via swift-users > wrote: > > I should note

Re: [swift-users] Linux Swift: Strange bug found in a simple arithmetic

2016-09-07 Thread Jon Shier via swift-users
It’s related to this: http://www.cocoawithlove.com/blog/2016/07/12/type-checker-issues.html Jon > On Sep 7, 2016, at 11:32 AM, Lou Zell via swift-users > wrote: > > Also hoping someone more knowledgeable can explain why these seemingly simple > cases do in fact take

Re: [swift-users] Capturing difference with typealias

2016-08-19 Thread Jon Shier via swift-users
Another general question I have is how the self requirement in general has changed. I’m noticing several instances where my previous @noescape closures, which of course had that attribute removed, are now requiring self when they didn’t before and aren’t marked @escaping either. So I guess my

[swift-users] Capturing difference with typealias

2016-08-19 Thread Jon Shier via swift-users
Users: I’m updating more code to beta 6 and have noticed a strange difference when calling functions with closure parameters where that closure is declared with a typealias. Take this class: typealias Closure = () -> Void class Thing { var array: [String] = [] func

Re: [swift-users] ProcessInfo arguments when running as a script?

2016-08-18 Thread Jon Shier via swift-users
ctually changed. > Swift.CommandLine (formerly Swift.Process, unrelated to ProcessInfo) should > have the script arguments only. > > Jordan > > >> On Aug 18, 2016, at 19:14, Jon Shier via swift-users <swift-users@swift.org> >> wrote: >> >> Swift Users: >>

[swift-users] ProcessInfo arguments when running as a script?

2016-08-18 Thread Jon Shier via swift-users
Swift Users: I’m trying to parse the command-line arguments of a Swift 3 script using Xcode 8 beta 6. However, ProcessInfo’s arguments array now contains all of the swift compiler arguments as well as the command itself. For example, this script: #!/usr/bin/env swift import Foundation

Re: [swift-users] Two Obj-C visible functions no longer overload?

2016-08-08 Thread Jon Shier via swift-users
king arrays of errors and now we do. > > Jordan > > >> On Aug 5, 2016, at 14:57, Jon Shier via swift-users <swift-users@swift.org >> <mailto:swift-users@swift.org>> wrote: >> >> Swifters: >> I’m attempting to update some library code to

[swift-users] SCNetworkReachabilityFlags beta 4 issue

2016-08-05 Thread Jon Shier via swift-users
Swifters: I’m attempting to port a library to Xcode 8 beta 4 and have run into a peculiar issue with SCNetworkReachabilityFlags. Prior to beta 4, this extension on SCNetworkReachabilityFlags which provided convenience Bool properties worked just fine: extension

Re: [swift-users] Date and Data

2016-08-03 Thread Jon Shier via swift-users
If you think Date and Data look similar at a glance, wouldn’t NSDate and NSData? Or are you comparing this against your old Array type? > On Aug 3, 2016, at 6:33 PM, Travis Griggs via swift-users > wrote: > > I realize this ship has probably sailed a long while ago. I

Re: [swift-users] Serial DispatchQueue and documentation?

2016-08-01 Thread Jon Shier via swift-users
Is it? I can’t tell by either the generated interface (default is not a useful value to expose) or a brief read of the Queue.swift file for it. Jon > On Aug 1, 2016, at 6:52 PM, Brent Royal-Gordon <br...@architechies.com> wrote: > >> On Aug 1, 2016, at 3:15 PM, Jon Shi

[swift-users] Serial DispatchQueue and documentation?

2016-08-01 Thread Jon Shier via swift-users
Swifters: It seems that in Xcode 8 beta 4, DispatchQueueAttributes was refactored to be DispatchQueue.Attributes but in the process lost the .serial attribute. How are we to create serial queues now? On a related note, where can we find the latest documentation for the Dispatch overlay?

[swift-users] Generic type metadata pattern not found?

2016-06-11 Thread Jon Shier via swift-users
Swift Users: In preparation for an upcoming iOS app project I’m trying out some new project layout strategies. One of which is putting my network layer and custom UI elements in frameworks separate from my main app. I’ve done this with frameworks in my project, and then used CocoaPods