Description: <short summary of the patch>
 TODO: Put a short summary on the line above and replace this paragraph
 with a longer explanation of this change. Complete the meta-information
 with other relevant fields (see below for details). To make it easier, the
 information below has been extracted from the changelog. Adjust it or drop
 it.
 .
 maxima (5.47.0-6) unstable; urgency=high
 .
   * build-dep gcl27
Author: Camm Maguire <camm@debian.org>

---
The information above should follow the Patch Tagging Guidelines, please
checkout https://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:

Origin: (upstream|backport|vendor|other), (<patch-url>|commit:<commit-id>)
Bug: <upstream-bugtracker-url>
Bug-Debian: https://bugs.debian.org/<bugnumber>
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
Forwarded: (no|not-needed|<patch-forwarded-url>)
Applied-Upstream: <version>, (<commit-url>|commit:<commid-id>)
Reviewed-By: <name and email of someone who approved/reviewed the patch>
Last-Update: 2025-04-26

--- maxima-5.47.0.orig/src/hypergeometric.lisp
+++ maxima-5.47.0/src/hypergeometric.lisp
@@ -365,7 +365,7 @@ ff(a,b,c,x,n) := block([f, f0 : 1, f1 :
     (setq d (delete-if #'(lambda(s) (null (second s))) d))
     ;; Sort d from least to greatest magnitude.
     ;;(print `(d = ,d))
-    (setq d (sort d #'(lambda (a b) (< (second a) (second b)))))
+    (setq d (stable-sort d #'(lambda (a b) (< (second a) (second b)))))
     (setq region (first (first d)))
     ;;(print `(region = ,region))
     ;;(print `(d = ,(second (first d))))
