[tracker/wip/carlosg/deserialize-api: 14/17] libtracker-sparql: Parse all numeric types in turtle deserializer
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/wip/carlosg/deserialize-api: 14/17] libtracker-sparql: Parse all numeric types in turtle deserializer
- Date: Thu, 30 Jun 2022 21:57:56 +0000 (UTC)
commit b8110ec94dac3c7f57e7adbb4415d50c9bb5ff00
Author: Carlos Garnacho <carlosg gnome org>
Date: Thu Jun 30 00:40:05 2022 +0200
libtracker-sparql: Parse all numeric types in turtle deserializer
We cannot take any shortcuts here, and must check for all numeric
types in the right order.
src/libtracker-sparql/tracker-deserializer-turtle.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
---
diff --git a/src/libtracker-sparql/tracker-deserializer-turtle.c
b/src/libtracker-sparql/tracker-deserializer-turtle.c
index 98d973458..c4b158084 100644
--- a/src/libtracker-sparql/tracker-deserializer-turtle.c
+++ b/src/libtracker-sparql/tracker-deserializer-turtle.c
@@ -652,7 +652,14 @@ tracker_deserializer_turtle_iterate_next (TrackerDeserializerTurtle *deserializ
} else if (!handle_type_cast (deserializer, error)) {
return FALSE;
}
- } else if (parse_terminal (deserializer, terminal_DOUBLE, 0, &str) ||
+ } else if (parse_terminal (deserializer, terminal_DOUBLE_POSITIVE, 0, &str) ||
+ parse_terminal (deserializer, terminal_DECIMAL_POSITIVE, 0, &str) ||
+ parse_terminal (deserializer, terminal_INTEGER_POSITIVE, 0, &str) ||
+ parse_terminal (deserializer, terminal_DOUBLE_NEGATIVE, 0, &str) ||
+ parse_terminal (deserializer, terminal_DECIMAL_NEGATIVE, 0, &str) ||
+ parse_terminal (deserializer, terminal_INTEGER_NEGATIVE, 0, &str) ||
+ parse_terminal (deserializer, terminal_DOUBLE, 0, &str) ||
+ parse_terminal (deserializer, terminal_DECIMAL, 0, &str) ||
parse_terminal (deserializer, terminal_INTEGER, 0, &str)) {
deserializer->object = str;
} else if (parse_token (deserializer, "true")) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]