diff --git a/11/type.cpp b/11/type.cpp index 8022966..05e85c6 100644 --- a/11/type.cpp +++ b/11/type.cpp @@ -114,7 +114,7 @@ void type_mgr::unify(type_ptr l, type_ptr r) { return; } else if((lid = dynamic_cast(l.get())) && (rid = dynamic_cast(r.get()))) { - if(lid->name == rid->name) return; + if(lid->name == rid->name && lid->arity == rid->arity) return; } else if((lapp = dynamic_cast(l.get())) && (rapp = dynamic_cast(r.get()))) { unify(lapp->constructor, rapp->constructor);