summaryrefslogtreecommitdiff
path: root/enc/utf_8.c
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-16 16:59:08 (GMT)
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-16 16:59:08 (GMT)
commitb3d772643e9eea84f71b168771f15d41d85e7341 (patch)
tree46735ef610896ec4b97f51bbc9998f6397f6fcb3 /enc/utf_8.c
parenta67d4fa01c43124048be957f7d8e4090b7255393 (diff)
fix typos.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19390 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'enc/utf_8.c')
-rw-r--r--enc/utf_8.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/enc/utf_8.c b/enc/utf_8.c
index 24f5fab..5913e78 100644
--- a/enc/utf_8.c
+++ b/enc/utf_8.c
@@ -255,11 +255,11 @@ static OnigCodePoint mbc_to_code(const UChar* p, const UChar* end, int *precise_
#define GRAPHEME_BIT_T 0x040
#define GRAPHEME_BIT_LV 0x080
#define GRAPHEME_BIT_LVT 0x100
-const struct graphme_table_t { /* codepoint_min <= c < codepoint_min+num_codepoints */
+const struct grapheme_table_t { /* codepoint_min <= c < codepoint_min+num_codepoints */
OnigCodePoint codepoint_min;
unsigned short num_codepoints;
unsigned short properties;
-} graphme_table[] = {
+} grapheme_table[] = {
{0x00000,32,0x001}, {0x0007F,33,0x001},
{0x000AD,1,0x001}, {0x00300,112,0x002},
{0x00483,7,0x002}, {0x00591,45,0x002},
@@ -801,8 +801,8 @@ const struct graphme_table_t { /* codepoint_min <= c < codepoint_min+num_codepoi
static int
grapheme_cmp(const void *p1, const void *p2)
{
- const struct graphme_table_t *k = p1;
- const struct graphme_table_t *v = p2;
+ const struct grapheme_table_t *k = p1;
+ const struct grapheme_table_t *v = p2;
OnigCodePoint c = k->codepoint_min;
if (c < v->codepoint_min)
return -1;
@@ -814,10 +814,10 @@ grapheme_cmp(const void *p1, const void *p2)
static unsigned int
get_grapheme_properties(OnigCodePoint c)
{
- struct graphme_table_t key, *found;
+ struct grapheme_table_t key, *found;
key.codepoint_min = c;
- found = bsearch(&key, graphme_table, sizeof(graphme_table)/sizeof(*graphme_table),
- sizeof(*graphme_table), grapheme_cmp);
+ found = bsearch(&key, grapheme_table, sizeof(grapheme_table)/sizeof(*grapheme_table),
+ sizeof(*grapheme_table), grapheme_cmp);
if (found)
return found->properties;
return 0;