| delorie.com/archives/browse.cgi | search |
| Xref: | news2.mv.net comp.os.msdos.djgpp:6084 |
| From: | Brad Burgan <bradtech AT i-link DOT net> |
| Newsgroups: | comp.os.msdos.djgpp |
| Subject: | Re: Why does this code not work? |
| Date: | Wed, 17 Jul 1996 09:44:03 -0500 |
| Organization: | Westpark Answering Service |
| Lines: | 22 |
| Message-ID: | <31ECFC33.2C8F@i-link.net> |
| References: | <31E983BD DOT 756D AT ix DOT netcom DOT com> |
| Reply-To: | bradtech AT i-link DOT net |
| NNTP-Posting-Host: | houston-1-14.i-link.net |
| Mime-Version: | 1.0 |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Bob Platko wrote:
>
> I can't get the following code to work in GCC. I keep getting warnings that the
> array has elements past what I defined the limit. It compiles perfectly in TCC.
>
> --code--
>
> const MAXPOLYS = 5;
> const POLYPOINTS = 4;
> const POLYCORDS = 3;
>
>
> signed short A[MAXPOLYS][POLYPOINTS][MAXPOLYS] =
^^^^^ should be POLYCORDS
> {
> { {-10, 10, 0},{ -2,-10, 0},{ 0,-10, 0},{ -5,10, 0} },
> { { -2,-10, 0},{ 2,-10, 0},{ 2, -5, 0},{ -2,-5, 0} },
> { { -6, 0, 0},{ 6, 0, 0},{ 7, 5, 0},{ -7, 5, 0} },
> { { 10, 10, 0},{ 2,-10, 0},{ 0,-10, 0},{ 5,10, 0} },
> { { 0, 0, 0},{ 0, 0, 0},{ 0, 0, 0},{ 0, 0, 0} } };
>
> --end--
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |