From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,e8550e5b10c2c0 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-03-03 01:24:04 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!kibo.news.demon.net!news.demon.co.uk!demon!not-for-mail From: john@nospam.demon.co.uk (John McCabe) Newsgroups: comp.lang.ada Subject: Re: Variant Record Component Date: Mon, 03 Mar 2003 09:24:54 GMT Message-ID: <3e631efc.2445356@news.demon.co.uk> References: <3E5D00D6.F6A20AD2@boeing.com> <3E5F8B38.EE7AE76F@boeing.com> NNTP-Posting-Host: assen.demon.co.uk X-Trace: news.demon.co.uk 1046683443 228 158.152.218.101 (3 Mar 2003 09:24:03 GMT) X-Complaints-To: abuse@demon.net NNTP-Posting-Date: Mon, 3 Mar 2003 09:24:03 +0000 (UTC) X-Newsreader: Forte Free Agent 1.21/32.243 Xref: archiver1.google.com comp.lang.ada:34819 Date: 2003-03-03T09:24:54+00:00 List-Id: On Fri, 28 Feb 2003 16:15:52 GMT, John Harbaugh wrote: >Here's the situation: I'm using a variant record to represent a Link 16 >(JTIDS) J7.6 message for memory-mapped I/O. So a message comes in and, >based on the message header, a particular structure is frozen. Now I >pass the message object to a decode function that is looking for >particular message fields. Well, surprise surprise, we occasionally >raise Constraint_Error because the field in question is not present. Areyou sure Constraint_Error is being raised because the field is not present? Are you checking the validity bits in the JTIDS message? Obviously if the validity bits identify a field as being not supplied, trying to process that field may result in a Constraint_Error if the data is out of range. Best Regards John McCabe To reply by email replace 'nospam' with 'assen'