ObjFW  Check-in [a40ccfa7cf]

Overview
Comment:Remove a useless ivar.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: a40ccfa7cf7b2ca1164cf13d0720bca0e759085960a0018a1a7ebc0583030e78
User & Date: js on 2012-11-02 21:19:41
Other Links: manifest | tags
Context
2012-11-02
21:39
Small fix in OFDictionaryEnumerator_hashtable. check-in: 62497de4c2 user: js tags: trunk
21:19
Remove a useless ivar. check-in: a40ccfa7cf user: js tags: trunk
2012-10-30
22:16
OFArray: Optimize fast enumeration. check-in: 365e946d10 user: js tags: trunk
Changes

Modified src/OFCountedSet_hashtable.h from [81f42e9cea] to [764c37fc25].

17
18
19
20
21
22
23
24
25
26
#import "OFCountedSet.h"

@class OFMutableDictionary_hashtable;

@interface OFCountedSet_hashtable: OFCountedSet
{
	OFMutableDictionary_hashtable *dictionary;
	unsigned long mutations;
}
@end







<


17
18
19
20
21
22
23

24
25
#import "OFCountedSet.h"

@class OFMutableDictionary_hashtable;

@interface OFCountedSet_hashtable: OFCountedSet
{
	OFMutableDictionary_hashtable *dictionary;

}
@end

Modified src/OFCountedSet_hashtable.m from [16ad1c4d5e] to [2d16b912f5].

212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
	if (count == nil)
		count = [OFNumber numberWithSize: 1];

	[dictionary OF_setObject: count
			  forKey: object
			 copyKey: NO];

	mutations++;

	objc_autoreleasePoolPop(pool);
}

- (void)removeObject: (id)object
{
	OFNumber *count = [dictionary objectForKey: object];
	void *pool;







<
<







212
213
214
215
216
217
218


219
220
221
222
223
224
225
	if (count == nil)
		count = [OFNumber numberWithSize: 1];

	[dictionary OF_setObject: count
			  forKey: object
			 copyKey: NO];



	objc_autoreleasePoolPop(pool);
}

- (void)removeObject: (id)object
{
	OFNumber *count = [dictionary objectForKey: object];
	void *pool;
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
	if ([count sizeValue] > 0)
		[dictionary OF_setObject: count
				  forKey: object
				 copyKey: NO];
	else
		[dictionary removeObjectForKey: object];

	mutations++;

	objc_autoreleasePoolPop(pool);
}

- (void)makeImmutable
{
}
@end







<
<







233
234
235
236
237
238
239


240
241
242
243
244
245
246
	if ([count sizeValue] > 0)
		[dictionary OF_setObject: count
				  forKey: object
				 copyKey: NO];
	else
		[dictionary removeObjectForKey: object];



	objc_autoreleasePoolPop(pool);
}

- (void)makeImmutable
{
}
@end

Modified src/OFMutableSet_hashtable.h from [0af0d9f3a8] to [ee1ba34d52].

17
18
19
20
21
22
23
24
25
26
#import "OFMutableSet.h"

@class OFMutableDictionary_hashtable;

@interface OFMutableSet_hashtable: OFMutableSet
{
	OFMutableDictionary_hashtable *dictionary;
	unsigned long mutations;
}
@end







<


17
18
19
20
21
22
23

24
25
#import "OFMutableSet.h"

@class OFMutableDictionary_hashtable;

@interface OFMutableSet_hashtable: OFMutableSet
{
	OFMutableDictionary_hashtable *dictionary;

}
@end

Modified src/OFMutableSet_hashtable.m from [6a160c9723] to [f1c4d45a2c].

31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
}

- (void)addObject: (id)object
{
	[dictionary OF_setObject: [OFNumber numberWithSize: 1]
			  forKey: object
			 copyKey: NO];

	mutations++;
}

- (void)removeObject: (id)object
{
	[dictionary removeObjectForKey: object];

	mutations++;
}

- (void)makeImmutable
{
	object_setClass(self, [OFSet_hashtable class]);
}
@end







<
<





<
<







31
32
33
34
35
36
37


38
39
40
41
42


43
44
45
46
47
48
49
}

- (void)addObject: (id)object
{
	[dictionary OF_setObject: [OFNumber numberWithSize: 1]
			  forKey: object
			 copyKey: NO];


}

- (void)removeObject: (id)object
{
	[dictionary removeObjectForKey: object];


}

- (void)makeImmutable
{
	object_setClass(self, [OFSet_hashtable class]);
}
@end