Behdad Esfahbod
4cb180d227
Revert "Use constexpr to replace passthru_ bools"
...
This reverts commit c4aa10ebc8
.
Broke several compilers... Sigh. The version without constexpr
didn't fully optimize out the unreachable code on clang.
So, revert it is...
2019-07-02 19:44:18 -07:00
Behdad Esfahbod
c4aa10ebc8
Use constexpr to replace passthru_ bools
2019-07-02 19:15:03 -07:00
Behdad Esfahbod
08c3648c6e
Oops, fix include
2019-05-17 16:21:34 -07:00
Behdad Esfahbod
24958b8868
[set] Use StructAtOffsetUnaligned
2019-05-17 16:20:36 -07:00
Behdad Esfahbod
f7a458510d
Add hb_bitwise_* ops
2019-05-15 16:53:12 -07:00
Behdad Esfahbod
889dc1eb06
[iter] Remove sort categorization
...
See comments.
2019-05-14 22:28:07 -07:00
Behdad Esfahbod
513762849a
[iter] Track strictly-sorted iterators
...
This make output of hb_enumerate() sorted regardless of input iterator.
2019-05-13 15:36:14 -07:00
Behdad Esfahbod
4c2fd05ca5
[iter] Implement range-based for loops
...
Part of https://github.com/harfbuzz/harfbuzz/issues/1648
2019-05-06 19:57:35 -07:00
Behdad Esfahbod
824fd342d5
Rename a few macros
2019-04-11 11:16:01 -04:00
Behdad Esfahbod
5bffa9e375
More
2019-04-02 20:13:16 -07:00
Behdad Esfahbod
849a0f1758
[iter] Add hb_iter_with_fallback_t instead
2019-01-29 17:10:19 -08:00
Behdad Esfahbod
4d40ed9d1a
[iter] Add hb_iter_with_mixin_t<>
2019-01-29 13:55:23 -08:00
Behdad Esfahbod
84a25d79c6
[iter] Rename
2019-01-29 13:39:19 -08:00
Behdad Esfahbod
a30e13469e
[iter] Add operator << to set / vector
2019-01-28 16:39:01 -05:00
Behdad Esfahbod
d438e61042
[iter] Fix operator() impls
2019-01-28 16:34:04 -05:00
Behdad Esfahbod
090fe56dc6
Merge branch 'master' into iter
2019-01-25 16:06:52 +01:00
Behdad Esfahbod
70a52d6bd8
Convert all other enum class consts to static constexpr
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/1553
2019-01-22 12:17:26 +01:00
Behdad Esfahbod
c1cbbb9459
Use static constexpr for large class constants
2019-01-22 10:51:20 +01:00
Behdad Esfahbod
a7de144df3
Implement uniform map interface
...
Coverage, ClassDef, hb_set_t, and hb_map_t implement.
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
636786ecaf
[iter] Rename __item_type__ to __item_t__
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
815cde9fa3
[iter] Use is_sorted_iterator
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
b5d6fe1a45
[iter] Remove hb_sorted_iter_t
...
Not enforcing it using type hierarchy.
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
5ec11ce13a
[iter] Clarify readonly vs lvalue iterators
...
lvalue iterators must declare __item_type__ as a reference.
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
6dc4a1c9b1
[iter] Remove const_iter
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
d3976b7e63
[iter] Make them work, mostly
2019-01-20 20:12:12 -05:00
Behdad Esfahbod
bd1318b8cc
Use static constexpr for large class constants
2019-01-20 19:47:52 -05:00
Behdad Esfahbod
043b610fa6
Fix sign compare warnings
...
../../third_party/harfbuzz-ng/src/src/hb-map.hh(56,45): warning: comparison of integers of different signs: 'const hb_codepoint_t' (aka 'const unsigned int') and 'hb_map_t::(anonymous enum at ../../third_party/harfbuzz-ng/src/src/hb-map.hh:169:3)' [-Wsign-compare]
bool is_unused () const { return key == INVALID; }
2019-01-19 09:21:33 -05:00
Behdad Esfahbod
fa333e34d6
[vector] Remove static_array
...
Was good idea, but with C++ types with constructor/destructor, was getting in
the way as compiler was destructing those items where it was not desired.
Since C++ does not allow zero-sized arrays, just remove it...
2018-12-27 17:56:22 -05:00
Behdad Esfahbod
e4355b1ca1
[set] Add iter_t as alias to const_iter_t
2018-12-23 20:34:24 -05:00
Behdad Esfahbod
33f8de6186
[set] Change to const_iter
2018-12-23 20:34:24 -05:00
Behdad Esfahbod
f88fed5cd8
[set] Cache length in iterator
2018-12-23 20:34:24 -05:00
Behdad Esfahbod
89d04129e2
[set] Actually derive iterator from hb_sorted_iter_t<>
2018-12-21 20:07:52 -05:00
Behdad Esfahbod
fc35919d01
[set] Implement unified iterator
2018-12-21 20:06:17 -05:00
Behdad Esfahbod
4911e67d2d
[set] Mark some internals protected
2018-12-21 20:00:52 -05:00
Behdad Esfahbod
474a12058d
[array/vector] Rename len to length
2018-12-21 18:53:01 -05:00
Behdad Esfahbod
9aebfb4182
[serialize] Streamline error propagation
2018-12-18 13:22:17 -05:00
Ebrahim Byagowi
e412008599
Remove redundant void from C++ sources ( #1486 )
2018-12-17 13:01:01 -05:00
Ebrahim Byagowi
b2ebaa9afa
Remove redundant 'inline' from methods ( #1483 )
2018-12-16 14:08:10 -05:00
Behdad Esfahbod
0f32c95e14
Fix a few more sizeof(vector[0]) errors with weird compilers
2018-11-30 11:31:39 -05:00
Behdad Esfahbod
861bc75349
[vector] Make pointer cast explicit
...
Too bad this doesn't help MSVC 2008 build, as explicit operators are
C++11.
2018-11-29 14:34:44 -05:00
Behdad Esfahbod
72955e6825
Hand-hold older compilers
2018-11-29 14:28:44 -05:00
Behdad Esfahbod
d77a098b73
[arrays] Improve bfind() interface
...
Much more useful now. :)
2018-11-24 10:06:13 -05:00
Behdad Esfahbod
22e1857b01
[arrays] Change argument type of cmp called by hb_vector_t.bsearch()
...
Towards consolidating all array bsearch/...
2018-11-24 09:48:06 -05:00
Behdad Esfahbod
d0e81b2cc8
[set] Rename
2018-11-22 21:20:39 -05:00
Behdad Esfahbod
af123bd1b8
Add hb_memcmp()
2018-11-12 16:27:08 -05:00
Behdad Esfahbod
5f97fe9956
Fix a few MSVC 2008 warnings
...
https://github.com/harfbuzz/harfbuzz/issues/1374
2018-11-09 10:01:50 -05:00
Behdad Esfahbod
93ef20a83b
Replace most uses of is_inert with is_immutable
2018-11-03 15:03:06 -04:00
Behdad Esfahbod
5854d3fa25
[set] Warning fix with gcc 8.1
...
https://github.com/harfbuzz/harfbuzz/pull/1334
2018-10-31 10:42:49 -07:00
Simon Tooke
881e1054bc
fix various GCC function pointer warnings
2018-10-30 13:17:54 -07:00
Behdad Esfahbod
b186274362
[set/map] Fix uninitialized memory
...
I keep forgetting that primitive types are NOT initialized during construction. :|
2018-10-29 23:21:14 -07:00