This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
optimise the sorting inplace of plain arrays: @a = sort @a
[perl5.git] / op.h
diff --git a/op.h b/op.h
index e957e1b..bd267b5 100644 (file)
--- a/op.h
+++ b/op.h
@@ -194,6 +194,7 @@ Deprecated.  Use C<GIMME_V> instead.
 #define OPpSORT_NUMERIC                1       /* Optimized away { $a <=> $b } */
 #define OPpSORT_INTEGER                2       /* Ditto while under "use integer" */
 #define OPpSORT_REVERSE                4       /* Descending sort */
+#define OPpSORT_INPLACE                8       /* sort in-place; eg @a = sort @a */
 /* Private for OP_THREADSV */
 #define OPpDONE_SVREF          64      /* Been through newSVREF once */