Article View: comp.lang.vhdl
Article #328data types, vhdl
From: Prince of Wales
Date: Sat, 02 Jan 1993 18:36
Date: Sat, 02 Jan 1993 18:36
29 lines
1312 bytes
1312 bytes
Hi folks, Is there any options in the vhdl language that lets me declare types equivalent to the "union" in C. The brute force method that I can think of is to declare a record with all the possible choices in the original union as a strictly present field; and have integer tags to access the types: e.g. -- pseudo vhdl code; type union is record -- the tag to determine what field to use; access_type : integer; -- this is where the union starts -- list is declared earlier as an access type to a list; u1 : real; u2 : integer; u3 : list end record; Is there any alternative to this lengthy way of designing a data structure. thanks for any replies and comments. ramanand -- ramanand@pumpkin.ece.uc.edu home: 513 281 9870 rmandaya@uceng.uc.edu office: 513 556 3025 mandayrv@ucunix.san.uc.edu ham: KB8GKL
Technical Details
Message-ID:
<C08p03.Htv@ucunix.san.uc.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!think.com!sdd.hp.com!news.cs.indiana.edu!babbage.ece.uc.edu!ucunix.san.uc.edu!mandayrvShow Full Headers
Complete Article Headers
Newsgroups: comp.lang.vhdl Path: arc1-ca.pugleaf.net!sparky!uunet!think.com!sdd.hp.com!news.cs.indiana.edu!babbage.ece.uc.edu!ucunix.san.uc.edu!mandayrv From: mandayrv@ucunix.san.uc.edu (Prince of Wales) Subject: data types, vhdl Message-ID: <C08p03.Htv@ucunix.san.uc.edu> Followup-To: poster Keywords: union, vhdl Organization: University of Cincinnati Distribution: usa Date: Sat, 2 Jan 1993 18:36:02 GMT Lines: 29