aboutsummaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2025-03-24Remove unnecessary condition and improve error message test coverageDavid Robillard1-2/+1
Not all of these cases are grammatically interesting, but the invalid characters are significant for error reporting (for example, error messages shouldn't contain raw control characters).
2025-03-24Simplify reading prefixed namesDavid Robillard1-4/+4
2025-03-22Remove dead codeDavid Robillard2-38/+6
2025-03-16Drop graphs when writing Turtle outputDavid Robillard1-7/+9
2025-03-16Encapsulate writer indentation codeDavid Robillard1-6/+4
This makes write_sep() responsible for all indentation changes (except resetting it to zero), removing some spooky action at a distance around object comma indentation.
2025-03-16Remove unused field and shrink WriteContextDavid Robillard1-6/+2
2025-03-16Remove redundant initializationDavid Robillard1-10/+1
2025-03-16Add missing parenthesesDavid Robillard1-1/+1
2025-03-16Consistently put function attributes firstDavid Robillard1-2/+2
2025-03-16Avoid "static inline" outside headersDavid Robillard1-1/+1
2025-03-16Remove unnecessary warning suppressionsDavid Robillard1-9/+0
Apparently clang 19 has gotten smarter about this.
2025-03-16Remove duplicate defineDavid Robillard1-3/+0
2025-03-16Factor out popping trailing dot characterDavid Robillard3-10/+15
2025-03-16Add missing includeDavid Robillard1-0/+2
2025-03-16Fix reading prefix names that start with "true." or "false."David Robillard1-67/+81
2025-03-16Fix reading numbers with no space before the final dotDavid Robillard1-7/+5
2025-03-16Refuse to write incoherent statementsDavid Robillard1-5/+12
2025-02-10Fully parenthesize expressionsDavid Robillard2-3/+3
2025-01-30Unify invalid input character error reportingDavid Robillard3-22/+26
Puts all error messages that print input characters in the same place, so that potentially printing them can be handled properly. Most notably this avoids printing EOF and control characters in error messages.
2025-01-30Fix handling of some invalid EOF cases in lax modeDavid Robillard1-6/+6
The return status of these tests unfortunately isn't consistent, so instead of testing for an exact exit status, instead check that the return status doesn't seem to be an abort() or other signal code (which are negative on Linux, while serdi itself never exits with a negative status).
2025-01-30Remove project and version number from man page OS fieldDavid Robillard1-1/+1
The mandoc documentation suggests leaving this blank. Although I still think it's nicer for third-party projects to put their own versions here (as many GNU utilities do, for example), it's a hassle in practice to maintain the version over time, and I'm not sure what to do about the date in that case. The version is passed to the mandoc command instead for generating the HTML man pages, so those are unchanged.
2025-01-18Serd 0.32.4v0.32.4David Robillard1-1/+1
2024-12-11Remove old Windows compatibility gunkDavid Robillard1-9/+0
2024-12-11Fix widening conversions after arithmeticDavid Robillard1-1/+1
Overflow isn't actually possible here, but this avoids the issue statically in a way that won't trigger analysis tools.
2024-12-11Invert condition to make lack of underflow more obviousDavid Robillard1-3/+3
2024-11-23Use angle brackets for library includesDavid Robillard18-19/+20
2024-11-22Use more conventional command-line help formattingDavid Robillard1-14/+14
2024-09-27Reorder branch to avoid redundant assignmentDavid Robillard1-4/+4
Well, to make it obvious to cppcheck that it's not redundant, anyway.
2024-09-27Fix potential null dereferenceDavid Robillard1-1/+1
2024-09-27Make more pointer variables constDavid Robillard3-9/+9
2024-09-27Make function parameters const wherever possibleDavid Robillard9-116/+132
The early history of this code didn't tend to make parameters const, but the "const density" is high enough now that I often find myself wondering if something is mutable for some reason, or just old and sloppier. So, eliminate this confusion by making (hopefully) all function parameters const if possible.
2024-09-27Use tighter types for UTF-8David Robillard3-16/+16
2024-09-27Remove unnecessary stdio.h includesDavid Robillard2-4/+3
2024-08-03Fix reading chunks from files without trailing newlinesDavid Robillard2-9/+8
2024-08-03Avoid bumping cursor column on EOFDavid Robillard1-2/+3
2024-07-16Suppress new warnings in clang and clang-tidy 18David Robillard1-1/+5
2024-06-25Simplify token comparison in readerDavid Robillard1-14/+20
"Simplify" in terms of the operations actually performed. Since we only need to test for equality here, a simpler comparison with less branching will do.
2024-06-25Reduce size of character classification codeDavid Robillard3-121/+24
2024-06-25Fix rewriting special literals when datatype URIs are prefixed namesDavid Robillard1-15/+30
2024-06-25Clean up redundant and/or inconsistent conditionalsDavid Robillard4-27/+19
2024-06-25Replace questionable switch statements with shorter conditionalsDavid Robillard7-97/+30
2024-06-25Fix overly permissive parsing of syntax names on the command lineDavid Robillard3-9/+14
2024-06-24Write blank lines between graphs and statements in TriGDavid Robillard1-1/+1
2024-06-24Clean up nonnull parameter assertionsDavid Robillard5-3/+32
2024-06-23Gracefully handle failure to terminate written anonymous nodesDavid Robillard1-14/+14
This case shouldn't be reachable when driven directly from a reader, but can be reached by invalid use of the writer in an application.
2024-06-23Gracefully handle errors while writing the end of anonymous nodesDavid Robillard1-1/+1
2024-06-22Strengthen clang-tidy configurationDavid Robillard1-3/+5
2024-06-22Avoid non-enum switches with missing default casesDavid Robillard2-25/+25
2024-06-09Treat out of range unicode characters as errorsDavid Robillard1-2/+2
2024-06-04Suppress new warnings in clang-tidy 17David Robillard1-1/+2