New module 'unictype/property-changes-when-uppercased'.
[gnulib.git] / lib / unictype / pr_byname.c
index fae5043..7f44a8c 100644 (file)
@@ -1,5 +1,5 @@
 /* Properties of Unicode characters.
-   Copyright (C) 2007 Free Software Foundation, Inc.
+   Copyright (C) 2007, 2009-2011 Free Software Foundation, Inc.
    Written by Bruno Haible <bruno@clisp.org>, 2007.
 
    This program is free software: you can redistribute it and/or modify it
@@ -23,7 +23,7 @@
 #include <string.h>
 
 /* Get gperf generated lookup function.  */
-#include "pr_byname.h"
+#include "unictype/pr_byname.h"
 
 static const uc_property_t UC_PROPERTY_NONE = { NULL };
 
@@ -40,16 +40,16 @@ uc_property_byname (const char *property_name)
     {
       unsigned char c = (unsigned char) *cp;
       if (c >= 0x80)
-       goto invalid;
+        goto invalid;
       if (c >= 'A' && c <= 'Z')
-       c += 'a' - 'A';
+        c += 'a' - 'A';
       else if (c == ' ' || c == '-')
-       c = '_';
+        c = '_';
       *bp = c;
       if (c == '\0')
-       break;
+        break;
       if (--count == 0)
-       goto invalid;
+        goto invalid;
     }
   found = uc_property_lookup (buf, bp - buf);
   if (found != NULL)