aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1/test/asn1_SUITE_data
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2013-10-17 15:22:49 +0200
committerBjörn Gustavsson <[email protected]>2013-10-17 15:54:29 +0200
commit719f789cebec004b350153e1f001303d6713f4a6 (patch)
tree774bd334dae867f22a6432dbda1e73cb0f36d881 /lib/asn1/test/asn1_SUITE_data
parent20641fe0f2ea745873fc7557448d3a7deb1bd639 (diff)
downloadotp-719f789cebec004b350153e1f001303d6713f4a6.tar.gz
otp-719f789cebec004b350153e1f001303d6713f4a6.tar.bz2
otp-719f789cebec004b350153e1f001303d6713f4a6.zip
Fix complicated union of INTEGER constraints
A constraint that was an union of integer ranges: Type ::= INTEGER (lb1..ub1 | ... | lbN..ubN) would sometimes (depending on the values) not all always be properly combined to a single effective range, but would become: Type ::= INTEGER (lb2..ub2) (lb3..ub3) If that type was used in a SEQUENCE: S ::= SEQUENCE { v Type } the constraint would be simplified, taking the intersection of the ranges.
Diffstat (limited to 'lib/asn1/test/asn1_SUITE_data')
-rw-r--r--lib/asn1/test/asn1_SUITE_data/Constraints.py40
1 files changed, 40 insertions, 0 deletions
diff --git a/lib/asn1/test/asn1_SUITE_data/Constraints.py b/lib/asn1/test/asn1_SUITE_data/Constraints.py
index e4bc987e4c..fcc8e4da31 100644
--- a/lib/asn1/test/asn1_SUITE_data/Constraints.py
+++ b/lib/asn1/test/asn1_SUITE_data/Constraints.py
@@ -94,4 +94,44 @@ pdf OBJECT IDENTIFIER ::= {1,2,3,4,5}
ShorterExt ::= IA5String (SIZE (5, ...))
+SeqOverlapping ::= SEQUENCE {
+ v Overlapping
+}
+
+SeqNonOverlapping ::= SEQUENCE {
+ v NonOverlapping
+}
+
+Overlapping ::= INTEGER (7280..7560 |
+7580..7680 |
+7910..8210 |
+8600..8940 |
+9250..9600 |
+14759..15109 |
+15250..15590 |
+18050..18800 |
+19300..19950 |
+21100..21700 |
+26200..26900 |
+18500..19900 |
+20100..20250 |
+21100..21700 |
+23000..24000 |
+24960..26900)
+
+-- The same intervals, but merged and sorted --
+NonOverlapping ::= INTEGER (7280..7560 |
+7580..7680 |
+7910..8210 |
+8600..8940 |
+9250..9600 |
+14759..15109 |
+15250..15590 |
+18050..19950 |
+20100..20250 |
+21100..21700 |
+23000..24000 |
+24960..26900)
+
+
END