blob: 579a06854fe635eb3cdac363ef5e361b220ccbf0 [file] [log] [blame]
Fariborz Jahanian97fd83a2010-01-11 21:17:32 +00001// RUN: %clang_cc1 -rewrite-objc -o - %s
2// rdar://6948022
3
4typedef unsigned int uint32_t;
5
6typedef struct {
7 union {
8 uint32_t daysOfWeek;
9 uint32_t dayOfMonth;
10 };
11 uint32_t nthOccurrence;
12} OSPatternSpecificData;
13
14@interface NSNumber
15+ (NSNumber *)numberWithLong:(long)value;
16@end
17
18@interface OSRecurrence {
19 OSPatternSpecificData _pts;
20}
21- (void)_setTypeSpecificInfoOnRecord;
22@end
23
24@implementation OSRecurrence
25- (void)_setTypeSpecificInfoOnRecord
26{
27 [NSNumber numberWithLong:(_pts.dayOfMonth >= 31 ? -1 : _pts.dayOfMonth)];
28}
29@end
30