Stable in-place sorting algorithm with time complexity O(n log n) implemented in Haskell
Implementations are based on the work of people from The Studio community Discord, who based theirs on Andrey Astrelin's. Links to their respective codes are below:
Collection of implementations in various languages: https://github.com/HolyGrailSortProject/Rewritten-Grailsort
Original implementation by Andrey Astrelin: https://github.com/Mrrl/GrailSort/blob/master/GrailSort.h