a new type of error to me?

This is a discussion on a new type of error to me? within the C++ Programming forums, part of the General Programming Boards category; hi, ive been compiling my program ok until i came across the following error FATAL ERROR (IMP302) The weird thing ...

  1. #1
    Registered User
    Join Date
    Apr 2008
    Posts
    99

    a new type of error to me?

    hi, ive been compiling my program ok until i came across the following error

    FATAL ERROR (IMP302)

    The weird thing is that the code im putting in seems to be correct to my eye. To check this out i was first running it in the borland command line compiler for quickness. This is where i get the error. I put it into the borland c++ builder 6 program and i got no errors? this seems a bit random to me? Is it some sort of size related error that the command line version can only handle so many lines? Seems strange that my program has hit around the 30000 lines mark then got this error? I would appreciated anyones input

    thanks

  2. #2
    Registered User
    Join Date
    Oct 2001
    Posts
    2,129

  3. #3
    Captain Crash brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,236
    The error code "IMP302" seems to indicate an "implementation" error, probably due to an implementation limit of the compiler, which in turn is probably due to your astoundingly huge source file. Break it into chunks.
    Code:
    //try
    //{
    	if (a) do { f( b); } while(1);
    	else   do { f(!b); } while(1);
    //}

  4. #4
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    I did a quick google, and it appears to be some form of linker limitation that causes this problem - from what I can tell - and one post said "spltting the project in halves solves the problem".

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  5. #5
    Banned master5001's Avatar
    Join Date
    Aug 2001
    Location
    Visalia, CA, USA
    Posts
    3,685
    That is an interesting, yet arbitrary limitation. I wonder why that is an issue. Splitting your code has the added advantage of making it more user friendly to others trying to read your code. If I need to look at the source for the FuzzyAnimal class, by golly I look in FuzzyAnimal.cpp.

  6. #6
    Registered User
    Join Date
    Oct 2001
    Posts
    2,129
    The line number needs to be recorded for errors and __LINE__ macros. The 30000 limit reported is close to the 16-bit signed integer limit of approximately 32767. Perhaps there are 32767 lines or more, and the line number is recorded in a 16-bit signed integer type.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 0
    Last Post: 03-20-2008, 07:59 AM
  2. Replies: 28
    Last Post: 07-16-2006, 11:35 PM
  3. Compiler "Warnings"
    By Jeremy G in forum A Brief History of Cprogramming.com
    Replies: 24
    Last Post: 04-24-2005, 01:09 PM
  4. Errors
    By Rhidian in forum C Programming
    Replies: 10
    Last Post: 04-04-2005, 12:22 PM
  5. gcc problem
    By bjdea1 in forum Linux Programming
    Replies: 13
    Last Post: 04-29-2002, 06:51 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21