Sync up with XEmacs 21.4.17.
[chise/xemacs-chise.git.1] / src / chartab.c
index 02ef2df..6eb6b32 100644 (file)
@@ -1235,15 +1235,16 @@ Return variants of CHARACTER.
 */
        (character))
 {
-  Lisp_Object ret;
-
   CHECK_CHAR (character);
-  ret = Fchar_feature (character, Q_ucs_unified, Qnil,
-                      Qnil, Qnil);
-  if (CONSP (ret))
-    return Fcopy_list (ret);
-  else
-    return Qnil;
+  return
+    nconc2
+    (Fcopy_list (Fget_char_attribute (character, Q_subsumptive, Qnil)),
+     (nconc2
+      (Fcopy_list (Fget_char_attribute (character, Q_denotational, Qnil)),
+       (nconc2
+       (Fcopy_list (Fget_char_attribute (character, Q_identical, Qnil)),
+        Fcopy_list (Fchar_feature (character, Q_ucs_unified, Qnil,
+                                   Qnil, Qnil)))))));
 }
 
 #endif
@@ -1391,7 +1392,7 @@ char_table_type_to_symbol (enum char_table_type type)
 {
   switch (type)
   {
-  default: abort();
+  default: ABORT();
   case CHAR_TABLE_TYPE_GENERIC:  return Qgeneric;
   case CHAR_TABLE_TYPE_SYNTAX:   return Qsyntax;
   case CHAR_TABLE_TYPE_DISPLAY:  return Qdisplay;
@@ -1849,7 +1850,7 @@ Reset CHAR-TABLE to its default state.
       break;
 
     default:
-      abort ();
+      ABORT ();
     }
 
   return Qnil;
@@ -2032,7 +2033,7 @@ XCHARSET_CELL_RANGE (Lisp_Object ccs)
       return (0 << 8) | 255;
 #endif
     default:
-      abort ();
+      ABORT ();
       return 0;
     }
 }
@@ -2094,7 +2095,7 @@ decode_char_table_range (Lisp_Object range, struct chartab_range *outrange)
        }
 #endif
       else
-       abort ();
+       ABORT ();
     }
   else
     {
@@ -2328,7 +2329,7 @@ If there is more than one value, return MULTI (defaults to nil).
 #endif /* not MULE */
 
     default:
-      abort ();
+      ABORT ();
     }
 
   return Qnil; /* not reached */
@@ -2378,7 +2379,7 @@ check_valid_char_table_value (Lisp_Object value, enum char_table_type type,
       break;
 
     default:
-      abort ();
+      ABORT ();
     }
 
   return 0; /* not reached */
@@ -2824,7 +2825,7 @@ map_char_table_for_charset_fun (struct chartab_range *range,
       break;
 
     default:
-      abort ();
+      ABORT ();
     }
 
   return 0;
@@ -3035,7 +3036,7 @@ map_char_table (Lisp_Char_Table *ct,
       }
 
     default:
-      abort ();
+      ABORT ();
     }
 
   return 0;
@@ -3081,7 +3082,7 @@ slow_map_char_table_fun (struct chartab_range *range,
       ranjarg = make_char (range->ch);
       break;
     default:
-      abort ();
+      ABORT ();
     }
 
   closure->retval = call2 (closure->function, ranjarg, val);
@@ -3508,10 +3509,11 @@ Store CHARACTER's ATTRIBUTE with VALUE.
            EQ (attribute, Q_component) ||
            EQ (attribute, Q_component_of) ||
            !NILP (Fstring_match
-                  (build_string ("^\\(<-\\|->\\)\\(simplified"
-                                 "\\|same\\|vulgar\\|wrong"
-                                 "\\|original\\|ancient"
-                                 "\\)[^*]*$"),
+                  (build_string ("^\\(<-\\|->\\)\\("
+                                 "fullwidth\\|halfwidth"
+                                 "\\|simplified\\|vulgar\\|wrong"
+                                 "\\|same\\|original\\|ancient"
+                                 "\\|Oracle-Bones\\)[^*]*$"),
                    Fsymbol_name (attribute),
                    Qnil, Qnil)) )
     {
@@ -3646,6 +3648,10 @@ open_chise_data_source_maybe ()
                         0 /* DB_HASH */, modemask);
       if (default_chise_data_source == NULL)
        return -1;
+#if 0
+      chise_ds_set_make_string_function (default_chise_data_source,
+                                        &make_string);
+#endif
     }
   return 0;
 }
@@ -3721,8 +3727,13 @@ char_table_get_db (Lisp_Char_Table* cit, Emchar ch)
 
   if (!status)
     {
+#if 0
       val = Fread (make_string (chise_value_data (&value),
                                chise_value_size (&value) ));
+#else
+      val = read_from_c_string (chise_value_data (&value),
+                               chise_value_size (&value) );
+#endif
     }
   else
     val = Qunbound;
@@ -3837,7 +3848,7 @@ Save values of ATTRIBUTE into database file.
                     (build_string ("^\\(<-\\|->\\)\\(simplified"
                                    "\\|same\\|vulgar\\|wrong"
                                    "\\|original\\|ancient"
-                                   "\\)[^*]*$"),
+                                   "\\|Oracle-Bones\\)[^*]*$"),
                      Fsymbol_name (attribute),
                      Qnil, Qnil)) )
        filter = &Fchar_refs_simplify_char_specs;
@@ -4345,7 +4356,7 @@ chartab_instantiate (Lisp_Object data)
                 Fput_char_table (make_char (i), val, chartab);
            }
          else
-           abort ();
+           ABORT ();
        }
       else
        Fput_char_table (range, val, chartab);