ObjFW  Diff

Differences From Artifact [de9d2023b1]:

To Artifact [80f6393652]:


15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
 */

#include "config.h"

#import "OFNull.h"
#import "OFString.h"
#import "OFXMLElement.h"
#import "OFDataArray.h"

#import "OFInvalidArgumentException.h"

@interface OFNull ()
- (OFString *)of_JSONRepresentationWithOptions: (int)options
					 depth: (size_t)depth;
@end







|







15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
 */

#include "config.h"

#import "OFNull.h"
#import "OFString.h"
#import "OFXMLElement.h"
#import "OFData.h"

#import "OFInvalidArgumentException.h"

@interface OFNull ()
- (OFString *)of_JSONRepresentationWithOptions: (int)options
					 depth: (size_t)depth;
@end
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119

- (OFString *)of_JSONRepresentationWithOptions: (int)options
					 depth: (size_t)depth
{
	return @"null";
}

- (OFDataArray *)messagePackRepresentation
{
	OFDataArray *data = [OFDataArray dataArrayWithItemSize: 1
						      capacity: 1];
	uint8_t type = 0xC0;

	[data addItem: &type];

	return data;
}

- autorelease
{
	return self;
}








|

<
<


|
|
<







97
98
99
100
101
102
103
104
105


106
107
108
109

110
111
112
113
114
115
116

- (OFString *)of_JSONRepresentationWithOptions: (int)options
					 depth: (size_t)depth
{
	return @"null";
}

- (OFData *)messagePackRepresentation
{


	uint8_t type = 0xC0;

	return [OFData dataWithItems: &type
			       count: 1];

}

- autorelease
{
	return self;
}