Discussion:
Help in custom error parsers
(too old to reply)
Anil Paryani
2003-12-03 21:25:13 UTC
Permalink
Any help would be appreciated. I want to double click on my output error window
and go straight to the error.

An example of an error is as follows:

:FE:C:\Projects\HII\Software\pack.c:186: pack_mampsec_dch undefined, int type
assumed

I have the custom regular expression

^:[A-Za-z]+:([a-zA-Z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$

Nothing happens when I double click on my output window.
Thom Little
2003-12-04 00:22:11 UTC
Permalink
It sounds like you don't have an error parser (or the correct error parser)
associated. It is set in

Project | Properties | Errors

At a minimum ...

Error Filename and Error Parser 1 need to be set appropriately. You may
need multiple error parsers.
--
-- Thom Little -- www.tlaNET.net -- Thom Little Associates, Ltd.
--
Post by Anil Paryani
Any help would be appreciated. I want to double click on my output error window
and go straight to the error.
:FE:C:\Projects\HII\Software\pack.c:186: pack_mampsec_dch undefined, int
type
Post by Anil Paryani
assumed
I have the custom regular expression
^:[A-Za-z]+:([a-zA-Z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$
Nothing happens when I double click on my output window.
Anil Paryani
2003-12-08 19:37:56 UTC
Permalink
I have doubled check that I have the correct error file associated. My error
file is currently being dumped to the output window. I am wondering if my
custome error parser is wrong.

Any regular expression experts out there who can verify tif I am using the
correct custom parser for my error line

^:[A-Za-z]+:([a-zA-Z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$

:FE:C:\Projects\HII\Software\serial.c:710: Lvalue required
Post by Thom Little
It sounds like you don't have an error parser (or the correct error parser)
associated. It is set in
Project | Properties | Errors
At a minimum ...
Error Filename and Error Parser 1 need to be set appropriately. You may
need multiple error parsers.
Thom Little
2003-12-08 20:22:11 UTC
Permalink
Are they assigned to Groups 1, 2, and 3 in that order?

Using a replace against your sample string...
:FE:C:\Projects\HII\Software\serial.c:710: Lvalue required

changing ...
^:[A-Za-z]+:([A-Za-z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$

to...
1=\1 2=\2 3=\3

verifies that the string is parsed

Is there some reason you don't just set one of the existing C error parsers
from the drop-down list?
--
-- Thom Little -- www.tlaNET.net -- Thom Little Associates, Ltd.
--
Post by Anil Paryani
I have doubled check that I have the correct error file associated. My error
file is currently being dumped to the output window. I am wondering if my
custome error parser is wrong.
Any regular expression experts out there who can verify tif I am using the
correct custom parser for my error line
^:[A-Za-z]+:([a-zA-Z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$
:FE:C:\Projects\HII\Software\serial.c:710: Lvalue required
Post by Thom Little
It sounds like you don't have an error parser (or the correct error parser)
associated. It is set in
Project | Properties | Errors
At a minimum ...
Error Filename and Error Parser 1 need to be set appropriately. You may
need multiple error parsers.
Anil Paryani
2003-12-09 20:21:15 UTC
Permalink
I can't find an existing C parser that correctly matches my compiler error (at
least the double clicking on the output window is not working). There are so
many parsers to choose from and none have worked that I have tried. Can you
suggest a few to try?

I am now wondering if the problem is not in my regular expression, but some how
in Project settings. I have verified that my compiler is outputting the correct
file as specified in the Error File Name. Is there anything else that I need to
configure in my project to get this to work?

Thanks for the help.

-Anil
Post by Thom Little
Are they assigned to Groups 1, 2, and 3 in that order?
Using a replace against your sample string...
:FE:C:\Projects\HII\Software\serial.c:710: Lvalue required
changing ...
^:[A-Za-z]+:([A-Za-z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$
to...
1=\1 2=\2 3=\3
verifies that the string is parsed
Is there some reason you don't just set one of the existing C error parsers
from the drop-down list?
Thom Little
2003-12-09 21:11:33 UTC
Permalink
You might try a "virgin" CodeWright:

Close the Project Space.
Close CodeWright.
Move cwright.ini out of the CodeWright root to a safe place (like the
desktop).
Move cwright.mac out of the CodeWright root to a safe place.
Copy cwright.i75 from the defaults subdirectory to the CodeWright root.
Rename cwright.i75 to cwright.ini.
Copy cwright.mac from the defaults subdirectory to the CodeWright root.

Install your parser making sure that it is for groups 1, 2, and 3
Run a test

Copy cwright.ini from the safe place to the CodeWright root.
Copy cwright.mac from the safe place to the CodeWright root.
Load CodeWright.
Open the Project Space.

If the test succeeded then your parameter information is contaminated.
--
-- Thom Little -- www.tlaNET.net -- Thom Little Associates, Ltd.
--
Post by Anil Paryani
I can't find an existing C parser that correctly matches my compiler error (at
least the double clicking on the output window is not working). There are so
many parsers to choose from and none have worked that I have tried. Can you
suggest a few to try?
I am now wondering if the problem is not in my regular expression, but some how
in Project settings. I have verified that my compiler is outputting the correct
file as specified in the Error File Name. Is there anything else that I need to
configure in my project to get this to work?
Thanks for the help.
-Anil
Post by Thom Little
Are they assigned to Groups 1, 2, and 3 in that order?
Using a replace against your sample string...
:FE:C:\Projects\HII\Software\serial.c:710: Lvalue required
changing ...
^:[A-Za-z]+:([A-Za-z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$
to...
1=\1 2=\2 3=\3
verifies that the string is parsed
Is there some reason you don't just set one of the existing C error parsers
from the drop-down list?
anonymous
2003-12-10 09:55:45 UTC
Permalink
Just a question.

Did you try out the additional error parsers that come with CW 7.5 ?
They have to be enabled using Tools/Customize/Libraries.
There are a lot of less used Error Parsers.

S. Zarifakis
Post by Thom Little
It sounds like you don't have an error parser (or the correct error parser)
associated. It is set in
Project | Properties | Errors
At a minimum ...
Error Filename and Error Parser 1 need to be set appropriately. You may
need multiple error parsers.
Thom Little
2003-12-11 11:05:01 UTC
Permalink
I copied a test .c file to d:\Current
Using your example I created an error file d:\Current\tlaTest.err
With no files loaded, tlaParse will load the error file into the Output
window Output pane
Double-click on any line in the Output window Output pane and the file
tlaMDE is loaded into an edit window and you are positioned to the line
identified as having the error.

--- d:\Current\tlaTest.err ---

:FE:D:\Current\tlaMDE.c:10: Lvalue required
:FE:D:\Current\tlaMDE.c:20: Lvalue required
:FE:D:\Current\tlaMDE.c:40: Lvalue required


--- tlaParse---

[API Macro:tlaParse]
// -------------------------------------------------------------------------
--------------
// tlaParse
// -------------------------------------------------------------------------
--------------

void tlaParse( void )
{
ErrorNextNew( TRUE, "d:\\Current\\tlaTest.err" );
return ;
}

// -------------------------------------------------------------------------
--------------
// 2003.12.11 05:40 Copyright © 1993-2003 - Thom Little Associates, Ltd. -
www.tlaNET.net


My GUESS is that you don't have the custom error parser connected. After
you create it you then have to select it from the drop-down list in Parser
1, 2, or 3. In my case the name appears as
_ErrorInfoParser_tlaTest
for the custom error parser I created with the name
_tlaTest

Let me know if this solves it.

As noted later in this string if you turn on the error parsers in Tools |
Customize... | Libraries you have a load of error parsers available for
selection. Your compiler is probably in the list.
--
-- Thom Little -- www.tlaNET.net -- Thom Little Associates, Ltd.
--
Post by Anil Paryani
Any help would be appreciated. I want to double click on my output error window
and go straight to the error.
:FE:C:\Projects\HII\Software\pack.c:186: pack_mampsec_dch undefined, int
type
Post by Anil Paryani
assumed
I have the custom regular expression
^:[A-Za-z]+:([a-zA-Z]:.*\.[a-zA-Z]+):([0-9]+): (.*)$
Nothing happens when I double click on my output window.
Loading...