aboutsummaryrefslogtreecommitdiffstats
path: root/tests/74-int-enum-constraints-OK.asn1
diff options
context:
space:
mode:
authorLev Walkin <vlm@lionet.info>2005-03-10 11:30:23 +0000
committerLev Walkin <vlm@lionet.info>2005-03-10 11:30:23 +0000
commit412dec9f6679deb3a6deaa3bb37cacd696f0051b (patch)
treebba2f36d32fce2cd728bd749811b3a44e091b6db /tests/74-int-enum-constraints-OK.asn1
parent4fe74d51d624e14607eaf194f7e77e84a9ceb3b0 (diff)
test for constraints on primitive types being defined
Diffstat (limited to 'tests/74-int-enum-constraints-OK.asn1')
-rw-r--r--tests/74-int-enum-constraints-OK.asn122
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/74-int-enum-constraints-OK.asn1 b/tests/74-int-enum-constraints-OK.asn1
new file mode 100644
index 00000000..9697788d
--- /dev/null
+++ b/tests/74-int-enum-constraints-OK.asn1
@@ -0,0 +1,22 @@
+
+-- OK: Everything is fine
+
+-- iso.org.dod.internet.private.enterprise (1.3.6.1.4.1)
+-- .spelio.software.asn1c.test (9363.1.5.1)
+-- .74
+
+ModuleTestIntegerAndEnumeratedConstraints
+ { iso org(3) dod(6) internet (1) private(4) enterprise(1)
+ spelio(9363) software(1) asn1c(5) test(1) 74 }
+ DEFINITIONS ::=
+BEGIN
+
+ -- Enumeration constrained by the second choice.
+ Enum ::= ENUMERATED { one, two } (two|one)
+
+ -- Integer constrained by the only choice.
+ Int ::= INTEGER { v1-0(123) } (v1-0)
+
+ EnumRef ::= Enum (two)
+
+END