Some examples of legal sub-typing:
Integer32 (-20..100) Integer32 (0..100 | 300..500) Integer32 (300..500 | 0..100) Integer32 (0 | 2 | 4 | 6 | 8 | 10) OCTET STRING (SIZE(0..100)) OCTET STRING (SIZE(0..100 | 300..500)) OCTET STRING (SIZE(0 | 2 | 4 | 6 | 8 | 10))
Some examples of illegal sub-typing:
Integer32 (150..100) -- first greater than second Integer32 (0..100 | 50..500) -- ranges overlap Integer32 (0 | 2 | 0 ) -- value duplicated Integer32 (MIN..-1 | 1..MAX) -- MIN and MAX not allowed Integer32 ((SIZE (0..34)) -- must not use SIZE OCTET STRING (0..100) -- must use SIZE OCTET STRING (SIZE(-10..100)) -- negative SIZE