Skip to content
Snippets Groups Projects
Unverified Commit e53277d8 authored by Sam James's avatar Sam James
Browse files

testsuite: add testcase for fixed PR98000

gcc/testsuite/ChangeLog:
	PR ipa/98000
	* g++.dg/ipa/pr98000.C: New test.
parent f9ff4784
No related branches found
No related tags found
No related merge requests found
/* { dg-do compile { target c++17 } } */
/* { dg-options "-Og -w" } */
struct {
template <typename T> T *operator()(T);
} hb_addressof;
template <typename, typename, typename... Ts> static int _hb_cmp_method(Ts...) {
return 0;
}
template <typename V, typename K>
inline bool hb_bsearch_impl(K key, V, int compar(void *, void *)) {
V p;
int __trans_tmp_2 = *hb_addressof(key) = compar(&__trans_tmp_2, p);
return false;
}
struct hb_array_t {
int arrayZ;
};
struct hb_sorted_array_t : hb_array_t {
void bsearch() {
hb_bsearch_impl(bsearch_impl_x, &arrayZ, _hb_cmp_method<int, int>);
}
int bsearch_impl_x;
};
template <typename Returned> struct hb_lazy_loader_t {
Returned *operator->();
};
namespace OT {
struct COLR;
}
struct hb_ot_face_t {
hb_lazy_loader_t<OT::COLR> COLR;
};
struct {
hb_ot_face_t table;
} hb_ot_color_glyph_get_layers_face;
namespace OT {
struct IntType {
typedef int wide_type;
operator wide_type();
};
struct UnsizedArrayOf;
struct OffsetTo {
template <typename Base> friend UnsizedArrayOf operator+(Base, OffsetTo);
};
template <typename, bool> using LOffsetTo = OffsetTo;
template <typename Type> using LNNOffsetTo = LOffsetTo<Type, false>;
struct UnsizedArrayOf {
void as_array(int);
};
struct SortedUnsizedArrayOf {
hb_sorted_array_t __trans_tmp_4;
void bsearch() { __trans_tmp_4.bsearch(); }
};
struct COLR {
SortedUnsizedArrayOf __trans_tmp_3;
int get_glyph_layers() {
__trans_tmp_3.bsearch();
int __trans_tmp_3 = numLayers;
(this + layersZ).as_array(__trans_tmp_3);
}
LNNOffsetTo<int> layersZ;
IntType numLayers;
};
} // namespace OT
void hb_ot_color_glyph_get_layers() {
hb_ot_color_glyph_get_layers_face.table.COLR->get_glyph_layers();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment