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=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Thread: 103376,b9880ab5a4975a57,start X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!news.glorb.com!news2.telebyte.nl!proxad.net!freenix!enst.fr!melchior!cuivre.fr.eu.org!melchior.frmug.org!not-for-mail From: "Robert C. Leif" Newsgroups: comp.lang.ada Subject: Object with zero bits Date: Tue, 12 Oct 2004 23:15:10 -0700 Organization: Newport Instruments Message-ID: Reply-To: rleif@rleif.com NNTP-Posting-Host: lovelace.ada-france.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: melchior.cuivre.fr.eu.org 1097648126 88164 212.85.156.195 (13 Oct 2004 06:15:26 GMT) X-Complaints-To: usenet@melchior.cuivre.fr.eu.org NNTP-Posting-Date: Wed, 13 Oct 2004 06:15:26 +0000 (UTC) To: Return-Path: X-Authenticated-User: rleif.rleif.com X-Mailer: Microsoft Office Outlook, Build 11.0.6353 Thread-Index: AcSw6/ESTgxpdUPDTyCI/SY6zUs87w== X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-MMX: 0 X-MMC: 227 X-MMR: 0 X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at ada-france.org X-BeenThere: comp.lang.ada@ada-france.org X-Mailman-Version: 2.1.4 Precedence: list List-Id: "Gateway to the comp.lang.ada Usenet newsgroup" List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Xref: g2news1.google.com comp.lang.ada:5127 Date: 2004-10-12T23:15:10-07:00 For the Ada implementation of the binary data part of CytometryML, I am using a discriminant to control a variant record where I need to store an object with a zero storage size. Instead of null, I would like a record with an object of 0 bits (Empty_Var). I have about 12 parameters and would like to be able to have the user determine which ones he or she will store. If all else fails, I can make a Boolean type that corresponds to one bit in a 32 bit unsigned integer and simply consider this 32 bit unsigned integer as excess baggage.. I do have the luxury that I can wait for Ada 2005. Will this capacity be in Ada 2005? If so, is there an example? type Fl_530_Rec_Type(Choice: Boolean) is record case Choice is when True => Part:Fl_530_Type := 0; --16 bit unsigned integer. when False => null; --Empty_Var:Empty_Type; end case; end record; Another approach, which I am trying to avoid is to store the data as a stream that contains different data-types. Thank you. Bob Leif