Overview
Comment: | Make OFDate a proper class cluster |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
3865cc56952edc9d8357767b81b460b7 |
User & Date: | js on 2023-08-08 21:06:58 |
Other Links: | manifest | tags |
Context
2023-08-08
| ||
21:16 | Make OFColor a proper class cluster check-in: ea9b62035b user: js tags: trunk | |
21:06 | Make OFDate a proper class cluster check-in: 3865cc5695 user: js tags: trunk | |
15:32 | A few minor cleanups check-in: a6f520157a user: js tags: trunk | |
Changes
Modified src/OFDate.h from [5d6447d0f7] to [0270f8788a].
︙ | |||
22 23 24 25 26 27 28 | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | - - - - - - - | @class OFConstantString; /** * @class OFDate OFDate.h ObjFW/OFDate.h * * @brief A class for storing, accessing and comparing dates. */ |
︙ |
Modified src/OFDate.m from [abe4f98453] to [93145b86e5].
︙ | |||
42 43 44 45 46 47 48 | 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 | - + - - + + + + - + | #import "OFOutOfRangeException.h" #if defined(OF_AMIGAOS_M68K) || defined(OF_MINT) /* amiga-gcc and freemint-gcc do not have trunc() */ # define trunc(x) ((int64_t)(x)) #endif |
︙ | |||
309 310 311 312 313 314 315 | 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 | + - + + + + + + + + + + + + + + + + + | value & ~(UINT64_C(4) << 60)); if (ret != nil) return ret; } #endif return (id)[[OFConcreteDate alloc] |
︙ | |||
359 360 361 362 363 364 365 | 378 379 380 381 382 383 384 385 386 387 388 389 390 391 | - - - - - | #endif #if defined(OF_OBJFW_RUNTIME) && UINTPTR_MAX == UINT64_MAX dateTag = objc_registerTaggedPointerClass([OFTaggedPointerDate class]); #endif } |
︙ | |||
424 425 426 427 428 429 430 | 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 | + + + + - - - - - + + + + + + + + | - (instancetype)init { return [self initWithTimeIntervalSince1970: now()]; } - (instancetype)initWithTimeIntervalSince1970: (OFTimeInterval)seconds { if ([self isMemberOfClass: [OFDate class]]) { @try { [self doesNotRecognizeSelector: _cmd]; } @catch (id e) { |
︙ | |||
829 830 831 832 833 834 835 | 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 | - + | return otherDate; return self; } - (OFTimeInterval)timeIntervalSince1970 { |
︙ |