Change Summary:
Make sure seralized tags starts with an
@
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+1128 -322) |
Review Request #3167 — Created May 7, 2024 and submitted
This object simplifies the interactions with tags. The user only ever deals with the raw tag values. The parser will unescape the tags and store them in the tags objects. Likewise, the serializer will escape the tags as it outputs them. Right now the tags object works like an ordered hash table. This is mostly for unit tests, but is probably fine going forward. That said, I'm not particularly fond of the implementation, but it does work so it's good enough for now.
Ran the parser and tags tests under valgrind.
Called in the turtles as well.
Summary | ID |
---|---|
5a6bbdc3dcdee62a29a6407747aec522a821c614 |
Description | From | Last Updated |
---|---|---|
Don't need the outer if since g_set_object should handle that. |
QuLogic | |
'for managing'? or 'to manage'? |
QuLogic | |
I don't think this correctly handles duplicate calls with the same key. Since the hash table owns the string, the … |
QuLogic | |
Comment should be deleted now. |
QuLogic | |
empty/missing values, I think, not tags. |
QuLogic | |
Remove? |
QuLogic | |
Can also add a parser test with duplicate tags in the input; I believe the spec says to use the … |
QuLogic | |
escapes? |
QuLogic |
Make sure seralized tags starts with an
@
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+1128 -322) |
ibis/ibistags.c (Diff revision 2) |
---|
I don't think this correctly handles duplicate calls with the same
key
. Since the hash table owns the string, the queue needs to be in sync with it. Butg_hash_table_insert
will freenew_key
if it's a duplicate, making this insertion into the queue invalid. You could useg_hash_table_replace
instead, but then you need to remove the old key pointer from the queue.I see only one test with repeated keys, but it's used for comparing with
ibis_tags_parse
, so won't iterate overtags->keys
.So there's a missing test for duplicate keys with
ibis_tags_serialize
, which would accesstags->keys
.
Addressed issues, added parser unit tests, added the escape tests from the spec, reworked how the ordered stuff works.
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 3 (+1664 -328) |
ibis/tests/test_tags.c (Diff revisions 2 - 3) |
---|
Can also add a parser test with duplicate tags in the input; I believe the spec says to use the last one.
Addressed issues, fixed other tests that were broken that i missed, also added tests for equals and contains.
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 4 (+2134 -362) |