From: "markww" <markww@gmail.com>
Subject: how to create a record
Date: 2 Nov 2006 19:14:58 -0800
Date: 2006-11-02T19:14:58-08:00 [thread overview]
Message-ID: <1162523698.802339.225760@h54g2000cwb.googlegroups.com> (raw)
Hi,
How can I define a record or a class to this source file and create an
instance of it?
with Ada.Text_IO;
type struct_device is
record
major_number : Integer := 0;
minor_number : Integer := 0;
end record;
procedure Ada_LinkedList is
begin
Ada.Text_IO.Put_Line("Hello, world!");
Ada.Text_IO.Put_Line("just terrible!");
end Ada_LinkedList;
I tried creating a record like in the above example, and compiling with
gnatmake but get the error:
C:\>gnatmake C:\Ada_LinkedList.adb
gcc -c -IC:\ -I- C:\ada_linkedlist.adb
ada_linkedlist.adb:4:05: compilation unit expected
gnatmake: "C:\ada_linkedlist.adb" compilation error
Thanks
next reply other threads:[~2006-11-03 3:14 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-03 3:14 markww [this message]
2006-11-03 4:48 ` how to create a record Jeffrey Creem
2006-11-03 5:29 ` Jeffrey R. Carter
2006-11-03 7:51 ` Maciej Sobczak
2006-11-03 5:00 ` jimmaureenrogers
2006-11-03 5:19 ` Jeffrey R. Carter
2006-11-03 11:51 ` Martin Krischik
2006-11-03 16:56 ` Pascal Obry
2006-11-04 3:09 ` Randy Brukardt
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox