engineerball
August 26th, 2007, 04:07 PM
How i can get number line of error from GCC ?
If I compile my program and have more errors. How can i got its.
Ex.
after I compile source code and it have errors.
read_str.cpp:5: error: ‘string’ was not declared in this scope
read_str.cpp:6: error: variable or field ‘Convert2D’ declared void
read_str.cpp:6: error: ‘string’ was not declared in this scope
read_str.cpp:7: error: ‘string’ has not been declared
read_str.cpp: In function ‘int main(int, char**)’:
read_str.cpp:25: error: ‘CountLine’ cannot be used as a function
read_str.cpp:26: error: ‘cout’ was not declared in this scope
read_str.cpp:26: error: ‘endl’ was not declared in this scope
read_str.cpp:29: error: cannot convert ‘std::string’ to ‘int’ for argument ‘2’ to ‘void FindLastLine(int*, int)’
read_str.cpp:36: warning: comparison between signed and unsigned integer expressions
I want 6, 7, 25, 26, 29, 36.
Can it get number from GCC direct ?
Sorry I'm very poor in English.
Thank you.
If I compile my program and have more errors. How can i got its.
Ex.
after I compile source code and it have errors.
read_str.cpp:5: error: ‘string’ was not declared in this scope
read_str.cpp:6: error: variable or field ‘Convert2D’ declared void
read_str.cpp:6: error: ‘string’ was not declared in this scope
read_str.cpp:7: error: ‘string’ has not been declared
read_str.cpp: In function ‘int main(int, char**)’:
read_str.cpp:25: error: ‘CountLine’ cannot be used as a function
read_str.cpp:26: error: ‘cout’ was not declared in this scope
read_str.cpp:26: error: ‘endl’ was not declared in this scope
read_str.cpp:29: error: cannot convert ‘std::string’ to ‘int’ for argument ‘2’ to ‘void FindLastLine(int*, int)’
read_str.cpp:36: warning: comparison between signed and unsigned integer expressions
I want 6, 7, 25, 26, 29, 36.
Can it get number from GCC direct ?
Sorry I'm very poor in English.
Thank you.