]> git.saurik.com Git - apple/icu.git/blame - icuSources/test/letest/letest.h
ICU-64260.0.1.tar.gz
[apple/icu.git] / icuSources / test / letest / letest.h
CommitLineData
f3c0d7a5
A
1// © 2016 and later: Unicode, Inc. and others.
2// License & terms of use: http://www.unicode.org/copyright.html
b75a7d8f
A
3/*
4 *******************************************************************************
5 *
b331163b 6 * Copyright (C) 1999-2014, International Business Machines
b75a7d8f
A
7 * Corporation and others. All Rights Reserved.
8 *
9 *******************************************************************************
10 * file name: letest.h
11 *
12 * created on: 11/06/2000
13 * created by: Eric R. Mader
14 */
15
73c04bcf
A
16#ifndef __LETEST_H
17#define __LETEST_H
18
b331163b
A
19
20#ifdef USING_ICULEHB
21#include "layout/LETypes.h"
22#else
b75a7d8f 23#include "LETypes.h"
b331163b 24#endif
46f4442e 25#include "unicode/ctest.h"
b75a7d8f 26
73c04bcf
A
27#include <stdlib.h>
28#include <string.h>
b75a7d8f 29
46f4442e
A
30U_NAMESPACE_USE
31
73c04bcf
A
32#define ARRAY_SIZE(array) (sizeof array / sizeof array[0])
33
34#define ARRAY_COPY(dst, src, count) memcpy((void *) (dst), (void *) (src), (count) * sizeof (src)[0])
b75a7d8f 35
73c04bcf 36#define NEW_ARRAY(type,count) (type *) malloc((count) * sizeof(type))
b75a7d8f 37
73c04bcf
A
38#define DELETE_ARRAY(array) free((void *) (array))
39
40#define GROW_ARRAY(array,newSize) realloc((void *) (array), (newSize) * sizeof (array)[0])
b75a7d8f
A
41
42struct TestResult
43{
44 le_int32 glyphCount;
45 LEGlyphID *glyphs;
46 le_int32 *indices;
47 float *positions;
48};
46f4442e 49
4388f060 50#ifndef __cplusplus
46f4442e
A
51typedef struct TestResult TestResult;
52#endif
53
54U_CFUNC void addCTests(TestNode **root);
55
73c04bcf 56#endif