1
0
mirror of https://github.com/stedolan/jq.git synced 2024-05-11 05:55:39 +00:00
Commit Graph

21 Commits

Author SHA1 Message Date
Nicolas Williams
cac14a531d Add index strings by string; return string indexes
% jq '.[","]'
    "a,bc,def,ghij,klmno"
    [1,4,8,13]
    %
2013-12-04 18:21:42 -06:00
Nicolas Williams
04bc2ef7cf Add jv_string_vfmt() 2013-12-04 18:21:41 -06:00
Nicolas Williams
884e6c7d8b Add string slicing 2013-12-04 18:21:39 -06:00
Nicolas Williams
cf562961b7 Add string division by string (split on separator) 2013-12-04 18:21:39 -06:00
Nicolas Williams
6c734cb609 Add explode/implode jq functions to match jv API 2013-12-04 18:21:38 -06:00
Nicolas Williams
ef41d1cb57 Use uint32_t for codepoint in jv_string_append_codepoint() 2013-12-04 18:21:38 -06:00
Nicolas Williams
08b4a34a8e Add jv string utility functions
jv_string_empty()
        -> return an empty string with given allocated length (for fast
           appends)
    jv_string_append_codepoint
        -> append a single codepoint (int) to the given string
    jv_string_explode
        -> return an array of codepoints making up a string
    jv_string_implode
        -> return the UTF-8 encoding of an array of codepoint numbers
2013-12-04 18:21:38 -06:00
Stephen Dolan
91cfc34ae4 Preserve insertion order in objects. Closes #169. 2013-12-04 22:30:39 +00:00
Stephen Dolan
dae2422fd1 Merge branch 'libjq'
Conflicts:
	Makefile.am
	configure.ac
2013-09-14 19:30:39 +01:00
Stephen Dolan
37cfc912c1 Remove #includes from jv.h 2013-06-23 14:23:07 +01:00
Stephen Dolan
ff48bd6ec5 Fix various UTF8 parsing bugs.
In particular, parse bad UTF8 by replacing the broken bits with U+FFFD
and resychronise correctly after broken sequences.
2013-06-22 13:34:24 +01:00
Stephen Dolan
e83e51eb56 'length' function now measures string length in codepoints, not bytes. 2013-05-15 00:37:38 +01:00
Stephen Dolan
b0e65d149f Fix a bug triggered by jv_array_slice. 2013-05-13 14:10:39 +01:00
Nicolas Williams
fb3c124af1 Rename complex to nontrivial for safety (#113) 2013-05-07 18:46:13 -05:00
Stephen Dolan
fb84541e11 Clean up jv_object_foreach and add jv_array_foreach 2012-12-31 23:27:00 +00:00
Stephen Dolan
79c9c418c6 Path manipulation (path/getpath/setpath/delpath) and docs.
del function should fix #37.
2012-12-28 16:08:29 +00:00
Stephen Dolan
04daafbde3 Add wrappers for malloc/realloc/free. See #43. 2012-12-18 16:53:51 +00:00
Stephen Roantree
1b556315af Remove redundant code from jv_object_contains 2012-10-25 06:29:23 -07:00
Stephen Roantree
ecc8998d38 Restructure contains methods to use public jv methods 2012-10-24 18:29:33 -07:00
Stephen Roantree
5e25c2a259 Implemented contains operator 2012-10-24 13:50:26 -07:00
Stephen Dolan
a4eea165bb Move everything around - delete old Haskell code, clean up build. 2012-09-18 17:44:43 +01:00