Signed-off-by: Alexandre Terrasa <alexandre@moz-code.org>
end
end
+# A `Comparator` to sort mentities by their names.
+class MEntityNameSorter
+ super Comparator
+
+ redef type COMPARED: MEntity
+
+ # Returns `a.name <=> b.name`.
+ redef fun compare(a, b) do return a.name <=> b.name
+end
+
# The visibility level `intrude`
fun intrude_visibility: MVisibility do return once new MVisibility("intrude", 5)
# The visibility level `public`
return res
end
end
-
-# Sorters
-
-# Sort mentities by their name
-class MEntityNameSorter
- super Comparator
- redef type COMPARED: MEntity
- redef fun compare(a, b) do return a.name <=> b.name
-end