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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,ecc058d81d1613b5 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit X-Received: by 10.66.89.39 with SMTP id bl7mr4937044pab.33.1356639907037; Thu, 27 Dec 2012 12:25:07 -0800 (PST) Received: by 10.50.179.103 with SMTP id df7mr8620765igc.16.1356639906978; Thu, 27 Dec 2012 12:25:06 -0800 (PST) Path: 6ni65509pbd.1!nntp.google.com!kr7no16727464pbb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 27 Dec 2012 12:25:06 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=69.153.58.182; posting-account=lJ3JNwoAAAAQfH3VV9vttJLkThaxtTfC NNTP-Posting-Host: 69.153.58.182 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <1dc74aed-badc-40fc-8182-b63d5e401686@googlegroups.com> Subject: Re: Help on record to a Newbie From: Shark8 Injection-Date: Thu, 27 Dec 2012 20:25:07 +0000 Content-Type: text/plain; charset=ISO-8859-1 Date: 2012-12-27T12:25:06-08:00 List-Id: Partitioning the code given into a package, called terminal, compiled quite easily. I cleaned up the names, a bit, too. -- Declare a package for defining types and operations on a terminal. Package Terminal is type terminal_type is (black_n_white, black_n_yellow, black_n_green, color); type terminal_color is (red, green, blue, yellow, black, white, grey); type terminal_configuration is record terminal : terminal_type; foreground, background : terminal_color; end record; -- Declare a variable for the configuration; use of this package implies -- usage of a terminal. t_config : terminal_configuration; End Terminal; Package Body Terminal is -- Here we set the defaults for the configuration. Alternatively, in the -- package specification we could have used named association to set the -- default: -- t_config : terminal_configuration := -- (Terminal => black_n_white, background => black, foreground => white); Begin t_config.terminal := black_n_white; t_config.background := black; t_config.foreground := white; End Terminal;