aboutsummaryrefslogtreecommitdiffstats
path: root/src/n3.c
AgeCommit message (Collapse)AuthorFilesLines
2023-12-02Factor out NQuads readerDavid Robillard1-91/+1
2023-12-02Factor out NTriples readerDavid Robillard1-516/+18
2023-12-02Factor out UTF-8 reading utilitiesDavid Robillard1-85/+10
2023-12-02Make r_err take a single line without trailing newlineDavid Robillard1-54/+53
Towards having an actual logging (rather than printing) mechanism.
2023-12-02Support reading lone lists in lax modeDavid Robillard1-1/+1
This allows parsing documents like "(42) ."
2023-12-02Be precise about the meaning of node "length" and "size"David Robillard1-2/+3
2023-12-02Handle read errors more preciselyDavid Robillard1-19/+20
2023-12-02Split up serd_internal.hDavid Robillard1-1/+1
2023-12-02Reduce complexity of blank node reading functionsDavid Robillard1-18/+28
2023-12-02Simplify statement flagsDavid Robillard1-21/+13
2023-12-02Improve reader error handlingDavid Robillard1-129/+152
2023-12-02Set flags directly when reading literal nodesDavid Robillard1-64/+43
2023-12-02Zero node padding before passing to reader sinksDavid Robillard1-1/+4
2023-12-02Remove datatype and language from reader contextDavid Robillard1-38/+32
2023-12-02Simplify stack management by popping in bulk at higher levelsDavid Robillard1-74/+37
Since all memory used by the reader is POD in the stack, there is no benefit to forcing code to explicitly pop everything pushed to the stack, since any function can record an offset and pop back down to it regardless of what its callers pushed if it knows that it does not need those items. This is slightly more efficient (due to avoiding many pop calls), but also more resilient since "leaks" at deeper levels of recursion get nuked by some caller regardless of what was pushed. This should help prevent future regressions like f6437f606 (Fix memory consumption when reading documents).
2023-12-02Use a fixed-size reader stackDavid Robillard1-116/+145
2023-12-02Add SerdSink interface and hide implementationsDavid Robillard1-11/+5
2023-12-02Merge datatype/language into nodeDavid Robillard1-14/+19
This moves closer to the sord API, and is more convenient in most cases.
2023-12-02Make nodes opaqueDavid Robillard1-16/+19
2023-12-02Use more human-readable status codesDavid Robillard1-81/+73
2023-12-02Split up public API headerDavid Robillard1-1/+5
2023-12-02Rename function types for consistencyDavid Robillard1-6/+6
2023-12-02Use char* for strings in public APIDavid Robillard1-7/+5
The constant casting just makes user code a mess, for no benefit.
2023-12-02Remove support for reading Turtle named inline nodes extensionDavid Robillard1-20/+0
2023-09-22Remove unused includeDavid Robillard1-1/+0
2023-05-08Avoid use of strtoul()David Robillard1-7/+7
This function is overkill for the simple cases actually needed here, and pretty slow anyway.
2023-05-03Make serd_reader_read_chunk() work with NQuadsDavid Robillard1-1/+1
2023-05-03Factor out read_nquads_statement()David Robillard1-42/+54
2023-04-16Gracefully handle errors when writing textDavid Robillard1-15/+14
2023-04-06Clean up error handling and use TRY macros more broadlyDavid Robillard1-29/+35
2023-04-06Improve pretty-printing of lists and inline subjectsDavid Robillard1-9/+14
2023-04-06Gracefully handle boolean subject and predicate errorsDavid Robillard1-0/+3
2023-04-05Improve writer error handlingDavid Robillard1-7/+1
2023-04-05Use conventional status variable nameDavid Robillard1-17/+17
2023-03-31Fix incorrect parsing of strange quote escape patternsDavid Robillard1-3/+9
2023-03-31Factor out read_string_escape()David Robillard1-11/+20
2022-12-20Avoid using ASCII grave as a quoteDavid Robillard1-15/+15
2022-12-09Add serd_reader_skip_until_byte() to public APIDavid Robillard1-4/+9
2022-11-25Always handle the return value of eat_byte_safe()David Robillard1-54/+40
2022-11-24Gracefully handle bad characters in Turtle blank node syntaxDavid Robillard1-1/+3
2022-11-24Gracefully handle bad characters in Turtle datatype syntaxDavid Robillard1-2/+5
2022-11-24Avoid redundant comparisonDavid Robillard1-1/+1
2022-11-24Simplify error handling logicDavid Robillard1-6/+5
2022-10-23Fix hang when skipping an error at EOF when lax parsingDavid Robillard1-1/+1
2022-10-23Use uppercase integer literal suffixesDavid Robillard1-3/+3
2022-08-31Adopt REUSE machine-readable licensing standardDavid Robillard1-15/+2
2022-06-10Fix memory consumption when reading documentsDavid Robillard1-1/+13
2021-05-31Make most function parameters constDavid Robillard1-69/+102
More const never hurts in general, but in particular this allows the compiler to make better nullability deductions, which reduces the amount of manual nullability casting required.
2021-05-31Remove "static inline" for functions in implementation filesDavid Robillard1-12/+12
This is just noise since these are static functions local to a C compilation unit.
2021-05-31Fix unannotated switch fallthroughsDavid Robillard1-4/+19
Unfortunately, clang does not support doing this with comments, requiring yet more preprocessor gunk.