Comment: | Remove OF_NULLABLE / OF_NONNULL
Now that Clang switched to use _Nullable and _Nonnull instead of This also defines _Null_unspecified to nothing if unavailable. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
d526d938d7860cbdec38687fa73b8c4b |
User & Date: | js on 2015-11-21 18:35:39 |
Other Links: | manifest | tags |
2015-11-21
| ||
19:15 | Make -[startTLSWithExpectedHost:] accept nil check-in: 684233314d user: js tags: trunk | |
18:35 | Remove OF_NULLABLE / OF_NONNULL check-in: d526d938d7 user: js tags: trunk | |
18:02 | Don't check for __thread if we have _Thread_local check-in: 18f1572e35 user: js tags: trunk | |
Modified src/OFApplication.h from [9035033dca] to [5756d4c723].
︙ | |||
180 181 182 183 184 185 186 | 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 | - - + + | /*! * @brief Gets args and argv. * * @param argc A pointer where a pointer to argc should be stored * @param argv A pointer where a pointer to argv should be stored */ |
︙ | |||
237 238 239 240 241 242 243 | 237 238 239 240 241 242 243 244 245 246 247 248 249 250 | - + | @interface OFObject (OFApplicationDelegate) <OFApplicationDelegate> @end #ifdef __cplusplus extern "C" { #endif |
Modified src/OFArray.h from [4267d7d56d] to [16fee25b86].
︙ | |||
65 66 67 68 69 70 71 | 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 | - + - + | /*! * @brief A block for mapping objects to objects in an OFArray. * * @param object The object to map * @param index The index of the object to map * @return The object to map to */ |
︙ | |||
136 137 138 139 140 141 142 | 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 | - + | * the specified length. * * @param objects A C array of objects * @param count The length of the C array * @return A new autoreleased OFArray */ + (instancetype) |
︙ | |||
181 182 183 184 185 186 187 | 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 | - + - + - - + | * @brief Initializes an OFArray with the objects from the specified C array of * the specified length. * * @param objects A C array of objects * @param count The length of the C array * @return An initialized OFArray */ |
︙ | |||
467 468 469 470 471 472 473 | 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 | - + | size_t _count; unsigned long _mutations; unsigned long *_mutationsPtr; size_t _position; } - initWithArray: (OFArray*)data |
Modified src/OFDictionary.h from [66a93812a2] to [77b3d41c42].
︙ | |||
34 35 36 37 38 39 40 | 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | - + | @class OFArray OF_GENERIC(ObjectType); #ifdef OF_HAVE_BLOCKS typedef void (^of_dictionary_enumeration_block_t)(id key, id object, bool *stop); typedef bool (^of_dictionary_filter_block_t)(id key, id object); |
︙ | |||
104 105 106 107 108 109 110 | 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 | - - + + | * * @param keys An array of keys * @param objects An array of objects * @param count The number of objects in the arrays * @return A new autoreleased OFDictionary */ + (instancetype) |
︙ | |||
157 158 159 160 161 162 163 | 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 | - - + + | * and objects. * * @param keys An array of keys * @param objects An array of objects * @param count The number of objects in the arrays * @return An initialized OFDictionary */ |
︙ |
Modified src/OFEnumerator.h from [30b2100737] to [74f0d63f69].
︙ | |||
88 89 90 91 92 93 94 | 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | - + - + | */ #define of_fast_enumeration_state_t NSFastEnumerationState #ifndef NSINTEGER_DEFINED typedef struct { /// Arbitrary state information for the enumeration unsigned long state; /// Pointer to a C array of objects to return |
︙ | |||
116 117 118 119 120 121 122 | 116 117 118 119 120 121 122 123 124 125 126 127 128 | - - + + | * @param state Context information for the enumeration * @param objects A pointer to an array where to put the objects * @param count The number of objects that can be stored at objects * @return The number of objects returned in objects or 0 when the enumeration * finished. */ - (int)countByEnumeratingWithState: (of_fast_enumeration_state_t*)state |
Modified src/OFHTTPRequest.h from [2b094f8687] to [cc2cdac436].
︙ | |||
237 238 239 240 241 242 243 | 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 | - + | #endif /*! * @brief Returns a C string describing the specified request method. * * @param method The request method which should be described as a C string * @return A C string describing the specified request method */ |
︙ |
Modified src/OFMapTable.h from [a855386419] to [fa70b8daed].
︙ | |||
24 25 26 27 28 29 30 | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | - + - + - + - + | /*! * @struct of_map_table_functions_t OFMapTable.h ObjFW/OFMapTable.h * * @brief A struct describing the functions to be used by the map table. */ typedef struct { /// The function to retain keys / values |
︙ | |||
52 53 54 55 56 57 58 | 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 | - + - | /*! * @brief A block for replacing values in an OFMapTable. * * @param key The key of the value to replace * @param value The value to replace * @return The value to replace the value with */ |
︙ |
Modified src/OFMutableArray.h from [665e799b10] to [1e74925f26].
︙ | |||
24 25 26 27 28 29 30 | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | - + | /*! * @brief A block for replacing values in an OFMutableArray. * * @param object The object to replace * @param index The index of the object to replace * @return The object to replace the object with */ |
︙ |
Modified src/OFMutableDictionary.h from [20d6c7fa26] to [cf03a53ce5].
︙ | |||
24 25 26 27 28 29 30 | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | - + | /*! * @brief A block for replacing objects in an OFMutableDictionary. * * @param key The key of the object to replace * @param object The object to replace * @return The object to replace the object with */ |
︙ |
Modified src/OFObject.h from [baf6f7542e] to [95294129a9].
︙ | |||
939 940 941 942 943 944 945 | 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 | - + | - (of_comparison_result_t)compare: (id <OFComparing>)object; @end #ifdef __cplusplus extern "C" { #endif extern id of_alloc_object(Class class_, size_t extraSize, |
Modified src/OFSet.h from [cac22c2803] to [b3a46a1679].
︙ | |||
103 104 105 106 107 108 109 | 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 | - + | /*! * @brief Creates a new set with the specified objects. * * @param objects An array of objects for the set * @param count The number of objects in the specified array * @return A new, autoreleased set with the specified objects */ |
︙ | |||
137 138 139 140 141 142 143 | 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 | - + | /*! * @brief Initializes an already allocated set with the specified objects. * * @param objects An array of objects for the set * @param count The number of objects in the specified array * @return An initialized set with the specified objects */ |
︙ |
Modified src/OFStdIOStream.h from [d6e15b6412] to [eb19e9f509].
︙ | |||
38 39 40 41 42 43 44 | 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | - + - + - + | extern "C" { #endif /*! @file */ /*! * @brief The standard input as an OFStream. */ |
Modified src/OFStream.h from [66ebb7f50c] to [4dfb1471ce].
︙ | |||
44 45 46 47 48 49 50 | 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | - + - + | * @param stream The stream on which data was read * @param buffer A buffer with the data that has been read * @param length The length of the data that has been read * @param exception An exception which occurred while reading or nil on success * @return A bool whether the same block should be used for the next read */ typedef bool (^of_stream_async_read_block_t)(OFStream *stream, void *buffer, |
︙ |
Modified src/OFString+XMLUnescaping.h from [8e9c5825f8] to [7a2761c9a2].
︙ | |||
33 34 35 36 37 38 39 | 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | - + | * @brief A block which is called to replace unknown XML entities in an XML * string. * * @param string The XML string which contains an unknown entity * @param entity The XML entity which is unknown * @return A replacement string for the unknown entity */ |
︙ |
Modified src/OFTCPSocket.h from [8b426328b2] to [68e32c48a9].
︙ | |||
30 31 32 33 34 35 36 | 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 | - + - + | * @brief A block which is called when the socket connected. * * @param socket The socket which connected * @param exception An exception which occurred while connecting the socket or * nil on success */ typedef void (^of_tcp_socket_async_connect_block_t)(OFTCPSocket *socket, |
︙ | |||
277 278 279 280 281 282 283 | 277 278 279 280 281 282 283 284 285 286 287 288 289 | - + | */ - (bool)isTCPNoDelayEnabled; @end #ifdef __cplusplus extern "C" { #endif |
Modified src/OFThread.h from [81d5aa4cdd] to [5636f9d458].
︙ | |||
30 31 32 33 34 35 36 | 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | - + | #if defined(OF_HAVE_THREADS) && defined(OF_HAVE_BLOCKS) /*! * @brief A block to be executed in a new thread. * * @return The object which should be returned when the thread is joined */ |
︙ |
Modified src/OFUDPSocket.h from [441994c3e5] to [24146b1f99].
︙ | |||
45 46 47 48 49 50 51 | 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | - + - + | * @param port The port of the host / port pair * @param address The address of the resolved host / port pair * @param exception An exception which occurred while resolving or nil on * success */ typedef void (^of_udp_socket_async_resolve_block_t)(OFString *host, uint16_t port, of_udp_socket_address_t address, |
︙ | |||
153 154 155 156 157 158 159 | 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | - - + + | * * @param host A pointer to an OFString*. If it is not NULL, it will be set to * the host of the host / port pair. * @param port A pointer to an uint16_t. If it is not NULL, the port of the * host / port pair will be written to it. * @param address The address for which the host and port should be retrieved */ |
︙ |
Modified src/OFZIPArchiveEntry.h from [c1f79ae163] to [c2340c1919].
︙ | |||
231 232 233 234 235 236 237 | 231 232 233 234 235 236 237 238 239 240 241 242 243 | - + | * the specified tag * @param tag The tag to look for * @param data A pointer to a pointer that should be set to the start of the * extra field with the specified tag * @param size A pointer to an uint16_t that should be set to the size */ extern void of_zip_archive_entry_extra_field_find(OFDataArray *extraField, |
Modified src/atomic.h from [6e95bb1842] to [5acf14775c].
︙ | |||
25 26 27 28 29 30 31 | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | - + | #ifdef OF_HAVE_OSATOMIC # include <libkern/OSAtomic.h> #endif OF_ASSUME_NONNULL_BEGIN static OF_INLINE int |
︙ | |||
74 75 76 77 78 79 80 | 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 | - + | return OSAtomicAdd32Barrier(i, p); #else # error of_atomic_int_add not implemented! #endif } static OF_INLINE int32_t |
︙ | |||
110 111 112 113 114 115 116 | 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 | - + | return OSAtomicAdd32Barrier(i, p); #else # error of_atomic_int32_add not implemented! #endif } static OF_INLINE void* |
︙ | |||
160 161 162 163 164 165 166 | 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 | - + | # endif #else # error of_atomic_ptr_add not implemented! #endif } static OF_INLINE int |
︙ | |||
211 212 213 214 215 216 217 | 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 | - + | return OSAtomicAdd32Barrier(-i, p); #else # error of_atomic_int_sub not implemented! #endif } static OF_INLINE int32_t |
︙ | |||
248 249 250 251 252 253 254 | 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 | - + | return OSAtomicAdd32Barrier(-i, p); #else # error of_atomic_int32_sub not implemented! #endif } static OF_INLINE void* |
︙ | |||
300 301 302 303 304 305 306 | 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 | - + | # endif #else # error of_atomic_ptr_sub not implemented! #endif } static OF_INLINE int |
︙ | |||
357 358 359 360 361 362 363 | 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 | - + | return OSAtomicIncrement32Barrier(p); #else # error of_atomic_int_inc not implemented! #endif } static OF_INLINE int32_t |
︙ | |||
399 400 401 402 403 404 405 | 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 | - + | return OSAtomicIncrement32Barrier(p); #else # error of_atomic_int32_inc not implemented! #endif } static OF_INLINE int |
︙ | |||
456 457 458 459 460 461 462 | 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 | - + | return OSAtomicDecrement32Barrier(p); #else # error of_atomic_int_dec not implemented! #endif } static OF_INLINE int32_t |
︙ | |||
498 499 500 501 502 503 504 | 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 | - + | return OSAtomicDecrement32Barrier(p); #else # error of_atomic_int32_dec not implemented! #endif } static OF_INLINE unsigned int |
︙ | |||
557 558 559 560 561 562 563 | 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 | - + | return OSAtomicOr32Barrier(i, p); #else # error of_atomic_int_or not implemented! #endif } static OF_INLINE uint32_t |
︙ | |||
598 599 600 601 602 603 604 | 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 | - + | return OSAtomicOr32Barrier(i, p); #else # error of_atomic_int32_or not implemented! #endif } static OF_INLINE unsigned int |
︙ | |||
657 658 659 660 661 662 663 | 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 | - + | return OSAtomicAnd32Barrier(i, p); #else # error of_atomic_int_and not implemented! #endif } static OF_INLINE uint32_t |
︙ | |||
698 699 700 701 702 703 704 | 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 | - + | return OSAtomicAnd32Barrier(i, p); #else # error of_atomic_int32_and not implemented! #endif } static OF_INLINE unsigned int |
︙ | |||
757 758 759 760 761 762 763 | 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 | - + | return OSAtomicXor32Barrier(i, p); #else # error of_atomic_int_xor not implemented! #endif } static OF_INLINE uint32_t |
︙ | |||
798 799 800 801 802 803 804 | 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 | - + | return OSAtomicXor32Barrier(i, p); #else # error of_atomic_int32_xor not implemented! #endif } static OF_INLINE bool |
︙ | |||
853 854 855 856 857 858 859 | 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 | - + | return OSAtomicCompareAndSwapIntBarrier(o, n, p); #else # error of_atomic_int_cmpswap not implemented! #endif } static OF_INLINE bool |
︙ | |||
908 909 910 911 912 913 914 | 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 | - - + + | return OSAtomicCompareAndSwap32Barrier(o, n, p); #else # error of_atomic_int32_cmpswap not implemented! #endif } static OF_INLINE bool |
︙ |
Modified src/instance.h from [8f8be6243f] to [4dd0773bd7].
︙ | |||
17 18 19 20 21 22 23 | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | - + | #import "macros.h" OF_ASSUME_NONNULL_BEGIN #ifdef __cplusplus extern "C" { #endif |
Modified src/macros.h from [2ef46745a0] to [9c39f051f0].
︙ | |||
166 167 168 169 170 171 172 | 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 | - - - - + + + | #else # define OF_GENERIC(...) #endif #if __has_feature(nullability) # define OF_ASSUME_NONNULL_BEGIN _Pragma("clang assume_nonnull begin") # define OF_ASSUME_NONNULL_END _Pragma("clang assume_nonnull end") |
︙ |
Modified src/of_asprintf.h from [7fb013ccb5] to [eedd732e01].
︙ | |||
27 28 29 30 31 32 33 | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | - + - + | OF_ASSUME_NONNULL_BEGIN #ifdef __cplusplus extern "C" { #endif extern int of_asprintf( |
Modified src/resolver.h from [f92afcb5a7] to [5d077f79a9].
︙ | |||
45 46 47 48 49 50 51 | 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | - - + + - - + + - + | * struct * @param protocol The protocol that should be inserted into the resulting * address struct * * @return An array of results. The list is terminated by NULL and should be * free'd after use. */ |