Article View: borland.public.csharpbuilder.compiler
Article #4Re: Initializing a Array of Classes.
From: JRobert
Date: Sat, 07 Aug 2004 07:44
Date: Sat, 07 Aug 2004 07:44
61 lines
2292 bytes
2292 bytes
Thanks a lot!, the struct hint and the way you pointed me works.
Marc Rohloff [TeamB] wrote:
> On Fri, 06 Aug 2004 22:14:12 +0100, JRobert wrote:
>
> Something like:
>
>
>
> OPCODE_NODE (ushort opmask, ushort op_code, OPCODETYPE opctype,
> CPUTYPE cpubits, ADDRMODE addrm)
> { this.opmask = opmask;
> ... }
>
The struct constructor had to be done _public_. I got a an error while
it wasn't.
>
> new OPCODE_MODE(0xffff, 0x003C, m_ORI, opct_CCR, ALL,
> IMPLIED),
> ...
>
This works also be only with this line:
...
new OPCODE_NODE (0xffff, 0x003C, MNEMONIC.ORI, OPCODETYPE.CCR,
CPUTYPE.ALL, ADDRMODE.IMPLIED),
I have to use the enum Name. Somehow there is a namespace problem if i
don't use the enum name.
My code looks like this.
----------->
namespace madis
{
#region MC68K Enumerations
public enum M68KType {M68000 = 0};
public enum MNEMONIC { ABCD=0,
ADDB, ADDW, ADDL,
ADDAW, ADDAL,
.
ORI,
.
public class m68kDisassembler
{
.
.
.
private static OPCODE_NODE[] Group_0x0 = {
new OPCODE_NODE (0xffff, 0x003C, MNEMONIC.ORI, OPCODETYPE.CCR,
CPUTYPE.ALL, ADDRMODE.IMPLIED),
.
.
.
---------->
Regards,
Robert
Technical Details
Message-ID:
<41147ac2@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<4113e6ee$1@newsgroups.borland.com> <1onofawj5e6bj$.dlg@marcrohloff.40tude.net>Show Full Headers
Complete Article Headers
X-Google-Thread: 1528ba,42c7b495a7aefb3d X-Google-Attributes: gid1528ba,public X-Google-Language: ENGLISH,ASCII-7-bit Date: Sat, 07 Aug 2004 08:44:56 +0100 From: JRobert <tsync@cronospec.de> User-Agent: Mozilla Thunderbird 0.7.2 (Windows/20040707) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: borland.public.csharpbuilder.compiler Subject: Re: Initializing a Array of Classes. References: <4113e6ee$1@newsgroups.borland.com> <1onofawj5e6bj$.dlg@marcrohloff.40tude.net> In-Reply-To: <1onofawj5e6bj$.dlg@marcrohloff.40tude.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 80.135.109.180 Message-ID: <41147ac2@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1091861186 80.135.109.180 (6 Aug 2004 23:46:26 -0700) Lines: 61 Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail