Differences From Artifact [5489126d7d]:
- File src/OFString+JSONParsing.m — part of check-in [1a86b8175b] at 2022-02-12 07:46:07 on branch trunk — Update copyright (user: js, size: 13160) [annotate] [blame] [check-ins using] [more...]
To Artifact [4b9a43cc0d]:
- File
src/OFString+JSONParsing.m
— part of check-in
[c86b8f10f0]
at
2022-11-16 01:27:26
on branch trunk
— Add OFAssert()
This uses the same format as OFEnsure(). (user: js, size: 13079) [annotate] [blame] [check-ins using] [more...]
︙ | ︙ | |||
16 17 18 19 20 21 22 | #include "config.h" #include <stdlib.h> #include <string.h> #include <math.h> | < < | 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | #include "config.h" #include <stdlib.h> #include <string.h> #include <math.h> #import "OFString+JSONParsing.h" #import "OFArray.h" #import "OFDictionary.h" #import "OFNumber.h" #import "OFNull.h" #import "OFInvalidJSONException.h" |
︙ | ︙ | |||
649 650 651 652 653 654 655 | { void *pool = objc_autoreleasePoolPush(); const char *pointer = self.UTF8String; const char *stop = pointer + self.UTF8StringLength; id object; size_t line = 1; | < < < < | 647 648 649 650 651 652 653 654 655 656 657 658 659 660 | { void *pool = objc_autoreleasePoolPush(); const char *pointer = self.UTF8String; const char *stop = pointer + self.UTF8StringLength; id object; size_t line = 1; object = nextObject(&pointer, stop, &line, depthLimit); skipWhitespacesAndComments(&pointer, stop, &line); if (pointer < stop || object == nil) @throw [OFInvalidJSONException exceptionWithString: self line: line]; |
︙ | ︙ |