bbcarchdev/liburi

Add property-accessors returning constant strings

Opened this issue · 1 comments

While the re-entrant buffer-copy APIs serve a purpose, for many applications there is a guarantee that multiple threads won't attempt to access the same URI object simultaneously, and so variants which return constant string pointers would simplify property access.

Is this a pattern you want to replicate everywhere, i.e. pairwise sets of safe vs. fast accessors? If so, I think we should adopt a nomenclature that is uniform across libraries, and personally, would prefer if the fast-but-thread-unsafe accessors were the ones 'marked' with a longer function name, e.g. (get_foo is the re-entrant version, get_foo_unsafe/get_shared_foo/whatever is not)