diff options
author | Jed Barber <jjbarber@y7mail.com> | 2017-02-13 15:36:49 +1100 |
---|---|---|
committer | Jed Barber <jjbarber@y7mail.com> | 2017-02-13 15:36:49 +1100 |
commit | 2b842cb65ce29071d5786bdecc834c026d1f2db2 (patch) | |
tree | 82ce0b4e660a7769fc2fb98280b9e9122f696780 /src | |
parent | ea99441e0da927e5a40cf21311265c7e22974f12 (diff) |
Fixed candidate ballot group ordering bug
Diffstat (limited to 'src')
-rw-r--r-- | src/candidates-containers.adb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/candidates-containers.adb b/src/candidates-containers.adb index 64a03ca..22249d3 100644 --- a/src/candidates-containers.adb +++ b/src/candidates-containers.adb @@ -78,7 +78,11 @@ package body Candidates.Containers is begin if SU.Length (Left.Group) = SU.Length (Right.Group) then if Left.Group = Right.Group then - return Left.Group_Rank < Right.Group_Rank; + if SU.Length (Left.Group_Rank) = SU.Length (Right.Group_Rank) then + return Left.Group_Rank < Right.Group_Rank; + else + return SU.Length (Left.Group_Rank) < SU.Length (Right.Group_Rank); + end if; else return Left.Group < Right.Group; end if; |