Behdad Esfahbod [Sun, 30 Dec 2018 23:42:14 +0000 (18:42 -0500)]
[iter/meta] Match hb_is_iterator<> using SFINAE
By specifying Item type, which is desirable.
Behdad Esfahbod [Sun, 30 Dec 2018 22:54:24 +0000 (17:54 -0500)]
Minor
Behdad Esfahbod [Sun, 30 Dec 2018 17:01:13 +0000 (12:01 -0500)]
Use C++11 when available
Behdad Esfahbod [Sun, 30 Dec 2018 16:22:16 +0000 (11:22 -0500)]
[ci] Remove unused config for gcc 4.2
[skip ci]
Behdad Esfahbod [Sun, 30 Dec 2018 16:16:14 +0000 (11:16 -0500)]
[ci] Disable other gcc 4.2 bot
Behdad Esfahbod [Sun, 30 Dec 2018 07:11:03 +0000 (02:11 -0500)]
[iter] Add back operator +
Too ugly to remove..
Behdad Esfahbod [Sun, 30 Dec 2018 06:40:08 +0000 (01:40 -0500)]
[iter] Disable operator +
To see if it makes bots happy... This is frustrating.
Behdad Esfahbod [Sat, 29 Dec 2018 02:23:26 +0000 (21:23 -0500)]
[iter] Revert back uses of C++11 auto type deduction
Behdad Esfahbod [Sat, 29 Dec 2018 02:22:26 +0000 (21:22 -0500)]
[iter] Rename
Behdad Esfahbod [Sat, 29 Dec 2018 02:09:15 +0000 (21:09 -0500)]
[iter] Remove friend operator +, hoping to fix some bots
Behdad Esfahbod [Sat, 29 Dec 2018 01:16:44 +0000 (20:16 -0500)]
Use Null() instead of declval(), hoping to fix some bots
Behdad Esfahbod [Sat, 29 Dec 2018 01:01:57 +0000 (20:01 -0500)]
[meta] Don't use template default arguments for functions
That's a C++11 extension apparently...
Behdad Esfahbod [Fri, 28 Dec 2018 21:41:04 +0000 (16:41 -0500)]
[meta] Fix unused-function-template warning
Behdad Esfahbod [Fri, 28 Dec 2018 21:29:48 +0000 (16:29 -0500)]
[iter/meta] Implement is_iterator
Removes use of auto type deduction again, which was not supported on many bots.
Behdad Esfahbod [Fri, 28 Dec 2018 19:40:30 +0000 (14:40 -0500)]
[meta] Minor
Behdad Esfahbod [Fri, 28 Dec 2018 19:34:00 +0000 (14:34 -0500)]
[meta] Move more code here
Behdad Esfahbod [Fri, 28 Dec 2018 19:29:09 +0000 (14:29 -0500)]
[iter/meta] Add hb_is_iterable
Behdad Esfahbod [Thu, 27 Dec 2018 23:39:39 +0000 (18:39 -0500)]
Don't use delegating constructors
Not all C++11 features are created equal when it comes to support...
Behdad Esfahbod [Thu, 27 Dec 2018 22:38:26 +0000 (17:38 -0500)]
[meta] Add enable_if
Behdad Esfahbod [Thu, 27 Dec 2018 22:23:12 +0000 (17:23 -0500)]
Add hb-meta.hh for meta-programming
Behdad Esfahbod [Thu, 27 Dec 2018 22:17:28 +0000 (17:17 -0500)]
[iter] Clarify readonly vs lvalue iterators
lvalue iterators must declare __item_type__ as a reference.
Behdad Esfahbod [Thu, 27 Dec 2018 21:55:18 +0000 (16:55 -0500)]
[iter] Test OT::Coverage iter
Behdad Esfahbod [Thu, 27 Dec 2018 21:29:22 +0000 (16:29 -0500)]
[iter] Streamline vector iterators
Behdad Esfahbod [Thu, 27 Dec 2018 18:29:51 +0000 (13:29 -0500)]
[iter] Make hb_sorted_array_t work as iter
Ugly, but does the job.
Behdad Esfahbod [Thu, 27 Dec 2018 14:56:41 +0000 (09:56 -0500)]
Change hb_void_t implementation
Behdad Esfahbod [Thu, 27 Dec 2018 14:39:34 +0000 (09:39 -0500)]
[iter] Mark Coverage iterator sorted
Behdad Esfahbod [Thu, 27 Dec 2018 03:50:33 +0000 (22:50 -0500)]
[subset] Take iterator in ArrayOf serialize
Still not satisfied with how I can enforce iterators only, but
seems to work for now.
Behdad Esfahbod [Thu, 27 Dec 2018 03:27:23 +0000 (22:27 -0500)]
[iter] Port Coverage iterator to hb_iter_t
Behdad Esfahbod [Thu, 27 Dec 2018 03:21:58 +0000 (22:21 -0500)]
Add hb_pair_t<> and hb_pair()
Behdad Esfahbod [Thu, 27 Dec 2018 03:08:54 +0000 (22:08 -0500)]
[Coverage] Ensure increasing coverage in iteration
Behdad Esfahbod [Thu, 27 Dec 2018 03:05:25 +0000 (22:05 -0500)]
[Coverage] Mark iterator methods const
Behdad Esfahbod [Thu, 27 Dec 2018 01:28:41 +0000 (20:28 -0500)]
[iter] Use operator bool in a few places
Behdad Esfahbod [Thu, 27 Dec 2018 01:06:10 +0000 (20:06 -0500)]
[iter] Remove redundant methods
Behdad Esfahbod [Thu, 27 Dec 2018 00:56:37 +0000 (19:56 -0500)]
[iter] Test default-constructability
Behdad Esfahbod [Thu, 27 Dec 2018 00:54:52 +0000 (19:54 -0500)]
[iter] Implement friend opeator + (int, iter)
Behdad Esfahbod [Thu, 27 Dec 2018 00:49:13 +0000 (19:49 -0500)]
[iter] Remove const_iter
Behdad Esfahbod [Thu, 27 Dec 2018 00:15:21 +0000 (19:15 -0500)]
[ci] Disable macos-llvm-gcc-4.2 again
Not C++11.
Behdad Esfahbod [Thu, 27 Dec 2018 00:14:39 +0000 (19:14 -0500)]
[iter] Remove hack for older compilers
Behdad Esfahbod [Thu, 27 Dec 2018 00:01:46 +0000 (19:01 -0500)]
[iter] Minor
Behdad Esfahbod [Thu, 27 Dec 2018 00:01:30 +0000 (19:01 -0500)]
[iter] Rename random_access() to constexpr is_random_access()
Behdad Esfahbod [Wed, 26 Dec 2018 23:58:42 +0000 (18:58 -0500)]
[iter] Add operator ->
Behdad Esfahbod [Wed, 26 Dec 2018 23:54:27 +0000 (18:54 -0500)]
[iter] Make them work, mostly
Behdad Esfahbod [Wed, 26 Dec 2018 23:54:15 +0000 (18:54 -0500)]
[vector] Add iterator
Behdad Esfahbod [Mon, 21 Jan 2019 01:09:10 +0000 (20:09 -0500)]
Remove wrongly added files
Behdad Esfahbod [Mon, 21 Jan 2019 00:51:08 +0000 (19:51 -0500)]
Use enum for class constant
Behdad Esfahbod [Mon, 21 Jan 2019 00:49:59 +0000 (19:49 -0500)]
[CFF] Use enum for tableTag
Behdad Esfahbod [Mon, 21 Jan 2019 00:47:52 +0000 (19:47 -0500)]
Use static constexpr for large class constants
Behdad Esfahbod [Sat, 19 Jan 2019 14:20:46 +0000 (09:20 -0500)]
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; }
Behdad Esfahbod [Sat, 19 Jan 2019 14:18:03 +0000 (09:18 -0500)]
Fix warning
warning: '_WIN64' is not defined, evaluates to 0 [-Wundef]
Ebrahim Byagowi [Sat, 19 Jan 2019 13:00:07 +0000 (16:30 +0330)]
[dwrite] Fix delete-non-virtual-dtor warning (#1550)
Behdad Esfahbod [Fri, 18 Jan 2019 19:59:18 +0000 (14:59 -0500)]
Remove TRACE_COLLECT_GLYPHS
Behdad Esfahbod [Fri, 18 Jan 2019 19:53:54 +0000 (14:53 -0500)]
[pragma] Only add if GCC or clang
Behdad Esfahbod [Fri, 18 Jan 2019 18:45:33 +0000 (13:45 -0500)]
[directwrite] More fix
Ebrahim Byagowi [Fri, 18 Jan 2019 18:25:21 +0000 (21:55 +0330)]
[dwrite] Try to fix delete-non-virtual-dtor warnings
Fixes #1548 hopefully
Behdad Esfahbod [Fri, 18 Jan 2019 17:53:06 +0000 (12:53 -0500)]
Remove tracing from closure
Behdad Esfahbod [Fri, 18 Jan 2019 17:48:01 +0000 (12:48 -0500)]
Fix -Wundef errors with __GNUC__
Fixes https://github.com/harfbuzz/harfbuzz/issues/1549
Michiharu Ariza [Fri, 18 Jan 2019 17:43:51 +0000 (09:43 -0800)]
init interp_env_t::hintmask_size
fixes issue #1547
Behdad Esfahbod [Fri, 18 Jan 2019 17:23:02 +0000 (12:23 -0500)]
[pragma] Enable error -Wdelete-non-virtual-dtor
Currently fails directwrite backend.
Behdad Esfahbod [Fri, 18 Jan 2019 17:22:07 +0000 (12:22 -0500)]
[directwrite] Fix error
hb-directwrite.cc: In constructor 'TextAnalysis::TextAnalysis(const wchar_t*, uint32_t, const wchar_t*, DWRITE_READING_DIRECTION)':
hb-directwrite.cc:489:18: error: 'TextAnalysis::mText' will be initialized after [-Werror=reorder]
const wchar_t* mText;
^~~~~
hb-directwrite.cc:488:12: error: 'uint32_t TextAnalysis::mTextLength' [-Werror=reorder]
uint32_t mTextLength;
^~~~~~~~~~~
hb-directwrite.cc:282:3: error: when initialized here [-Werror=reorder]
TextAnalysis (const wchar_t* text, uint32_t textLength,
^~~~~~~~~~~~
hb-directwrite.cc: In function 'hb_bool_t _hb_directwrite_shape_full(hb_shape_plan_t*, hb_font_t*, hb_buffer_t*, const hb_feature_t*, unsigned int, float)':
Behdad Esfahbod [Fri, 18 Jan 2019 15:08:23 +0000 (10:08 -0500)]
[pragma] More cast-align whitelist
Behdad Esfahbod [Fri, 18 Jan 2019 15:03:43 +0000 (10:03 -0500)]
[pragma] Allow cast-align in hb-font.cc
../src/hb-machinery.hh: In instantiation of 'const Type& StructAtOffset(const void*, unsigned int) [with Type = unsigned int]':
../src/hb-font.cc:144:85: required from here
../src/hb-machinery.hh:63:12: error: cast from 'const char*' to 'const unsigned int*' increases required alignment of target type [-Werror=cast-align]
{ return * reinterpret_cast<const Type*> ((const char *) P + offset); }
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/hb-machinery.hh: In instantiation of 'Type& StructAtOffset(void*, unsigned int) [with Type = unsigned int]':
../src/hb-font.cc:145:79: required from here
../src/hb-machinery.hh:66:12: error: cast from 'char*' to 'unsigned int*' increases required alignment of target type [-Werror=cast-align]
{ return * reinterpret_cast<Type*> ((char *) P + offset); }
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/hb-machinery.hh: In instantiation of 'Type& StructAtOffset(void*, unsigned int) [with Type = int]':
Behdad Esfahbod [Fri, 18 Jan 2019 14:59:36 +0000 (09:59 -0500)]
[pragma] GCC diagnostic error "-Wreorder"
Behdad Esfahbod [Fri, 18 Jan 2019 14:53:16 +0000 (09:53 -0500)]
[pragma] GCC diagnostic warning "-Wmaybe-uninitialized"
Behdad Esfahbod [Fri, 18 Jan 2019 14:49:14 +0000 (09:49 -0500)]
[pragma] Massage more
Behdad Esfahbod [Fri, 18 Jan 2019 14:46:17 +0000 (09:46 -0500)]
[pragma] More
Behdad Esfahbod [Fri, 18 Jan 2019 14:28:22 +0000 (09:28 -0500)]
[pragma] Reorg again
https://github.com/harfbuzz/harfbuzz/issues/1546
Behdad Esfahbod [Fri, 18 Jan 2019 13:49:45 +0000 (08:49 -0500)]
[pragma] GCC diagnostic ignored "-Wunknown-warning-option"
Try at fixing https://github.com/harfbuzz/harfbuzz/issues/1546
Behdad Esfahbod [Fri, 18 Jan 2019 00:58:54 +0000 (19:58 -0500)]
[uniscribe] More warnings
Behdad Esfahbod [Fri, 18 Jan 2019 00:57:17 +0000 (19:57 -0500)]
[uniscribe] Fix warnings
Behdad Esfahbod [Fri, 18 Jan 2019 00:52:32 +0000 (19:52 -0500)]
Fix build
Behdad Esfahbod [Fri, 18 Jan 2019 00:33:41 +0000 (19:33 -0500)]
[pragma] GCC diagnostic ignored "-Wclass-memaccess"
Behdad Esfahbod [Fri, 18 Jan 2019 00:12:07 +0000 (19:12 -0500)]
[ci] Remove unnecessary warning declarations
clang -Weverything still left to be ported to pragmas
Behdad Esfahbod [Fri, 18 Jan 2019 00:03:33 +0000 (19:03 -0500)]
[pragma] ignored -Wunsafe-loop-optimizations // TODO fix
Behdad Esfahbod [Fri, 18 Jan 2019 00:02:06 +0000 (19:02 -0500)]
[pragma] error -Wclass-memaccess
Behdad Esfahbod [Thu, 17 Jan 2019 23:55:03 +0000 (18:55 -0500)]
[pragma] More
Behdad Esfahbod [Thu, 17 Jan 2019 23:47:32 +0000 (18:47 -0500)]
[pragma] More
Behdad Esfahbod [Thu, 17 Jan 2019 23:36:10 +0000 (18:36 -0500)]
[pragma] Flesh out more
Behdad Esfahbod [Thu, 17 Jan 2019 23:24:18 +0000 (18:24 -0500)]
Use NNOffsetTo<> in rest of places
Behdad Esfahbod [Thu, 17 Jan 2019 23:17:04 +0000 (18:17 -0500)]
Use NNOffsetTo<>
Behdad Esfahbod [Thu, 17 Jan 2019 23:10:38 +0000 (18:10 -0500)]
Add NNOffsetTo<>
Behdad Esfahbod [Thu, 17 Jan 2019 22:56:27 +0000 (17:56 -0500)]
[AAT] Comment
Behdad Esfahbod [Thu, 17 Jan 2019 22:49:55 +0000 (17:49 -0500)]
Comment
Behdad Esfahbod [Thu, 17 Jan 2019 22:47:29 +0000 (17:47 -0500)]
[AAT] Remove unused code
Behdad Esfahbod [Thu, 17 Jan 2019 22:44:39 +0000 (17:44 -0500)]
[AAT] Allow null in ankr lookupTable offset
Behdad Esfahbod [Thu, 17 Jan 2019 22:42:44 +0000 (17:42 -0500)]
[pragma GCC] Ignore -Wtype-limits
Behdad Esfahbod [Thu, 17 Jan 2019 21:07:27 +0000 (16:07 -0500)]
[ci] Remove -Werror from Travis
hb-machinery.hh:111:37: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
Also ignore -Wtype-limits.
Behdad Esfahbod [Thu, 17 Jan 2019 20:27:31 +0000 (15:27 -0500)]
More GCC pragmas
Behdad Esfahbod [Thu, 17 Jan 2019 20:22:46 +0000 (15:22 -0500)]
Rename macro
Behdad Esfahbod [Thu, 17 Jan 2019 20:22:28 +0000 (15:22 -0500)]
Add more GCC warning pragmas
Behdad Esfahbod [Thu, 17 Jan 2019 20:08:36 +0000 (15:08 -0500)]
Move -Wcast-align to hb.hh
Behdad Esfahbod [Thu, 17 Jan 2019 20:04:44 +0000 (15:04 -0500)]
Add pragram GCC diagnostic ignored "-Wunused-macros"
Behdad Esfahbod [Thu, 17 Jan 2019 19:54:32 +0000 (14:54 -0500)]
[AAT] Fully sanitize ankr table at sanitize time
Third try to fix access. Followup
6879efc2c1596d11a6a6ad296f80063b558d5e0f
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=12532
Fixes https://bugs.chromium.org/p/chromium/issues/detail?id=922303
Behdad Esfahbod [Thu, 17 Jan 2019 19:06:37 +0000 (14:06 -0500)]
[AAT] Fix anchor bound checking, again
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=12532
Fixes https://bugs.chromium.org/p/chromium/issues/detail?id=922303
Behdad Esfahbod [Thu, 17 Jan 2019 19:06:32 +0000 (14:06 -0500)]
[aat] Minor
Behdad Esfahbod [Tue, 15 Jan 2019 18:58:19 +0000 (13:58 -0500)]
Improve overflow avoidance
Better fix for
480406cd3ef9e5ab8476ddfa04498bf23906c508
This way we behave the same on 32bit and 64bit archs.
Behdad Esfahbod [Tue, 15 Jan 2019 02:23:17 +0000 (18:23 -0800)]
fix FDSelect fuzzing bug (#1539)
Rewrote struct FDSelect3_4.ranges as ArrayOf
Updated FDSelect3_4::sanitize () to call ranges.sanitize ()
nRanges now a function to return a reference to ranges.len
Behdad Esfahbod [Tue, 15 Jan 2019 01:45:31 +0000 (20:45 -0500)]
Move _POSIX_SOURCE definition
Fixes https://github.com/harfbuzz/harfbuzz/issues/1308
Behdad Esfahbod [Mon, 14 Jan 2019 20:31:31 +0000 (15:31 -0500)]
[test] Add test for previous commit
Behdad Esfahbod [Mon, 14 Jan 2019 20:27:34 +0000 (15:27 -0500)]
Fix assertion on address overflow
Fixes https://bugs.chromium.org/p/chromium/issues/detail?id=917031
Behdad Esfahbod [Mon, 14 Jan 2019 20:09:14 +0000 (15:09 -0500)]
[AAT] Fix mort ContextualSubtable offset access
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=12312