Iterate through inline warnings and errors?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
JoBr_1593366
Level 5
Level 5
100 sign-ins 50 questions asked 100 replies posted

Is there a way to go through the whole workspace and find these types of errors/warnings that appear on the left side?

JoBr_1593366_0-1618595938669.png

 

JoBr_1593366_1-1618595995207.png

 

Or just list them in the same way the Notice List does, where I can double-click to go to the location in the code?

The project builds and doesn't show anything about these in the Notice List, but I'd like to be able to get them all sorted out, to make sure there are no subtle bugs, etc.

 

0 Likes
3 Replies
KyTr_1955226
Level 6
Level 6
250 sign-ins 10 likes given 50 solutions authored

Those unknown types would definitely show as a build error in the notice list if they were real.  Have you tried just restarting PSoC Creator?  Sometimes when I see "phantom" errors like this in an IDE, restarting the application clears it up.

In my case, if I try and use an actual undefined type, I see it in the Notice List and my build fails:

KyTr_1955226_5-1618600679407.png

KyTr_1955226_6-1618600706740.png

Maybe in your case there's some funny business going on with the order of your includes?  cytypes.h is where those typedefs reside, and it is included as part of the generated project.h header

 

That comparison of a pointer and an integer looks like a legitimate warning though, and it should appear in the notice list on build.  Me doing something similar in my own project does show up in the Notice List:

KyTr_1955226_0-1618599615897.png

KyTr_1955226_2-1618599663121.png

Do you have Errors and Warnings selected (blue highlights like the above screencap) in your notice list?  If you don't have them selected, it will filter them out from the list and you won't see them. 

I would also check the build settings.  If the warning level setting is set to "None", that would make it so they don't show up in your Notice List

KyTr_1955226_7-1618600933448.png

 

0 Likes

@KyTr_1955226 wrote:

Those unknown types would definitely show as a build error in the notice list if they were real.  Have you tried just restarting PSoC Creator?

No, they aren't "phantom", and don't go away when restarting, and don't show up in the Notice List.


Maybe in your case there's some funny business going on with the order of your includes?  cytypes.h is where those typedefs reside, and it is included as part of the generated project.h header

That might be it.  Like missing include guards, etc.?


That comparison of a pointer and an integer looks like a legitimate warning though, and it should appear in the notice list on build. 


No, it doesn't show up in the Notice List, only as the "linter" type warnings, which is why I'd like to go through all of them and eliminate them.


Do you have Errors and Warnings selected (blue highlights like the above screencap) in your notice list?


Yep:

JoBr_1593366_0-1618602346871.png


I would also check the build settings.  If the warning level setting is set to "None", that would make it so they don't show up in your Notice List

KyTr_1955226_7-1618600933448.png


Warning level is 2, though note that this is PK51, not GCC:

JoBr_1593366_1-1618602544582.png

 

0 Likes

Ah, things will be a little different between the PSoC3 (Keil 8051) and PSoC5 (GCC ARM) compilers.  I think you might possibly be on the right track with include guards/order for the unknown type errors.

 

As far as the warning goes, I can confirm (using the 8051 compiler this time) the warning for a integer and pointer comparison does not appear in the Notice List.  I was using GCC ARM for my testing in my last post, which actually throws a true warning from the compiler for comparing a pointer and an integer.  Looking through all the Warning and Error codes in the Keil 8051 documentation, it looks like the Kiel 8051 compiler does not have a warning for that condition, so it must be the code parser in creator only that's picking it up and reporting it.  Maybe the parser for PSoC Creator uses GCC for error/warning detection for both 8051 and ARM projects?

I don't think there's a way to show it on the notice list, but maybe someone from Cypress can prove me wrong on that.  I'd be a little worried about missing bugs as well if warnings aren't showing up in the Notice List.