]> mj.ucw.cz Git - leo.git/blobdiff - sym.c
Symbolizers may visually compare two symbols
[leo.git] / sym.c
diff --git a/sym.c b/sym.c
index 752bea609cf6bf2d128301a8616d033b2ebd3beb..c9780198d1e017fed75168292cd705c6e406d379 100644 (file)
--- a/sym.c
+++ b/sym.c
@@ -155,3 +155,15 @@ struct symbol * sym_copy(struct symbol *sym)
   else
     return NULL;
 }
+
+bool sym_look_same(struct symbol *s1, struct symbol *s2)
+{
+  if (s1->type != s2->type)
+    return false;
+
+  ASSERT(s1->type && s1->type < SYMBOLIZER_MAX);
+  if (symbolizers[s1->type]->look_same)
+    return symbolizers[s1->type]->look_same(s1, s2);
+  else
+    return false;
+}