ObjFW  Check-in [94c7e3e8f3]

Overview
Comment:OFDate: Also ignore -Wunknown-pragmas

This makes old versions of Clang happy which don't know about
-Wobjc-designated-initializers.

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | tagged-pointers
Files: files | file ages | folders
SHA3-256: 94c7e3e8f3eefbfceef5502de4cdb8c3b94ffb45bbeec69c709f354187b8e3fe
User & Date: js on 2020-07-25 18:32:42
Other Links: branch diff | manifest | tags
Context
2020-07-26
21:09
lookup-asm-x86_64-macho.S: Fix missing @GOTPCREL Leaf check-in: 4cf6858694 user: js tags: tagged-pointers
2020-07-25
18:32
OFDate: Also ignore -Wunknown-pragmas check-in: 94c7e3e8f3 user: js tags: tagged-pointers
17:24
OFDate: Fix missing #ifdef check-in: 096c2662d6 user: js tags: tagged-pointers
Changes

Modified src/OFDate.m from [1dcb1c7fda] to [8d4b356936].

277
278
279
280
281
282
283

284
285
286
287
288
289
290
}
@end

@implementation OFDatePlaceholder
#ifdef __clang__
/* We intentionally don't call into super, so silence the warning. */
# pragma clang diagnostic push

# pragma clang diagnostic ignored "-Wobjc-designated-initializers"
#endif
- (instancetype)initWithTimeIntervalSince1970: (of_time_interval_t)seconds
{
#if defined(OF_OBJFW_RUNTIME) && UINTPTR_MAX == UINT64_MAX
	uint64_t value;
#endif







>







277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
}
@end

@implementation OFDatePlaceholder
#ifdef __clang__
/* We intentionally don't call into super, so silence the warning. */
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wunknown-pragmas"
# pragma clang diagnostic ignored "-Wobjc-designated-initializers"
#endif
- (instancetype)initWithTimeIntervalSince1970: (of_time_interval_t)seconds
{
#if defined(OF_OBJFW_RUNTIME) && UINTPTR_MAX == UINT64_MAX
	uint64_t value;
#endif

Modified src/macros.h from [41e131467f] to [98097ba1eb].

413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
		[self release];				\
		@throw e;				\
	}						\
							\
	abort();
#endif
#ifdef __clang__
# define OF_DEALLOC_UNSUPPORTED						\
	[self doesNotRecognizeSelector: _cmd];				\
									\
	abort();							\
									\
	_Pragma("clang diagnostic push ignore \"-Wunreachable-code\"");	\
	[super dealloc];	/* Get rid of a stupid warning */	\
	_Pragma("clang diagnostic pop");
#else
# define OF_DEALLOC_UNSUPPORTED						\
	[self doesNotRecognizeSelector: _cmd];				\
									\
	abort();							\
									\







|
|
|
|
|
|
|







413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
		[self release];				\
		@throw e;				\
	}						\
							\
	abort();
#endif
#ifdef __clang__
# define OF_DEALLOC_UNSUPPORTED						 \
	[self doesNotRecognizeSelector: _cmd];				 \
									 \
	abort();							 \
									 \
	_Pragma("clang diagnostic push ignored \"-Wunreachable-code\""); \
	[super dealloc];	/* Get rid of a stupid warning */	 \
	_Pragma("clang diagnostic pop");
#else
# define OF_DEALLOC_UNSUPPORTED						\
	[self doesNotRecognizeSelector: _cmd];				\
									\
	abort();							\
									\