just a minor question:
I tried to use the async sockets for UDP sockets with ARC under iOS5
sdk, but ran into the problem that the arc branch does not contain the
UDP class, and the master branch's AsyncUdpSocket and GCDAsyncUdpSocket
do not compile with ARC and regular compiler settings. It's not just
simple changes of pointer handling. The compiler also complains about
some gotos, that jump over variable declarations and thus break the ref
counting.
I'm currently a beginner with iOS programming and busy with getting used
to it, so I'm not yet really familiar with every detail of the former
and the new memory management model. My assumption is that the main
changes will be to replace methods like retain, release with simple
pointer assignments, but replacing the gotos would require changes in
the program's logic and flow.
Is anyone more experienced with iOS and the asyncsocket library planning
to make a ARC version of the UDP socket?
best regards
Hadmut
>I tried to use the async sockets for UDP sockets with ARC under iOS5
>sdk, but ran into the problem that the arc branch does not contain the
>UDP class, and the master branch's AsyncUdpSocket and GCDAsyncUdpSocket
>do not compile with ARC and regular compiler settings. It's not just
>simple changes of pointer handling. The compiler also complains about
>some gotos, that jump over variable declarations and thus break the ref
>counting.
I haven't tried the ARC branch, but CocoaAsyncSocket doesn't need to support ARC to work in an ARC application. ARC apps can use manual ref counted code, just add -fno-objc-arc to any files that aren't ARC.
--
____________________________________________________________
Sean McBride, B. Eng se...@rogue-research.com
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
Yeah, I've seen that somewhere, but I'm not sure whether it is a good
idea to mix code with and without that flag. I always prefer the clean
version over the workaround. And for the TCP socket, there is for some
reason a separate arc version. So maybe the UDP version is under
construction as well...
regards
> --
> You received this message because you are subscribed to the Google Groups "CocoaAsyncSocket" group.
> To post to this group, send email to cocoaasy...@googlegroups.com.
> To unsubscribe from this group, send email to cocoaasyncsock...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/cocoaasyncsocket?hl=en.
>