CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

#ignore_warnings - can you ignore 202 and 226?

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
allenhuffman



Joined: 17 Jun 2019
Posts: 638
Location: Des Moines, Iowa, USA

View user's profile Send private message Visit poster's website

#ignore_warnings - can you ignore 202 and 226?
PostPosted: Tue Sep 23, 2025 12:22 pm     Reply with quote

The Wiznet library has a number of things that cause compiler warnings. Since we won't fix them, I am ignoring them when the files are included:

Code:
#ignore_warnings 202,203,204,209,226,237
    // Include Wiznet in include path:
    #include "Ethernet/wizchip_conf.c"      // Include first.
    #include "Ethernet/socket.c"
    #include "Ethernet/W5500/w5500.c"
    //#include "Internet/httpServer/httpServer.c"
#ignore_warnings NONE


But, I still get 202 and 226 warnings:

Quote:
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_readdata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_readdata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_writedata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_writedata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_readdata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_readdata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_writedata SCR=22742
>>> Warning 226 "main.c" Line 127(1,1): Function never called wizchip_bus_writedata SCR=22742
>>> Warning 202 "Ethernet\socket.c" Line 218(14,24): Variable never used: local_port


I even tried "#ignore_warnings ALL".

Is there a trick I need to know?
_________________
Allen C. Huffman, Sub-Etha Software (est. 1990) http://www.subethasoftware.com
Embedded C, Arduino, MSP430, ESP8266/32, BASIC Stamp and PIC24 programmer.
http://www.whywouldyouwanttodothat.com ?

Using: 24FJ256GA106, 24EP256GP202 and 24FJ64GA002.
dyeatman



Joined: 06 Sep 2003
Posts: 1967
Location: Norman, OK

View user's profile Send private message

PostPosted: Tue Sep 23, 2025 2:25 pm     Reply with quote

I have never had this issue.
All of my #ignore_warning directives have worked.
Maybe a compiler issue CCS needs to be advised...?
_________________
Google and Forum Search are some of your best tools!!!!
allenhuffman



Joined: 17 Jun 2019
Posts: 638
Location: Des Moines, Iowa, USA

View user's profile Send private message Visit poster's website

PostPosted: Tue Sep 23, 2025 4:57 pm     Reply with quote

Good to know. I have a support e-mail going with them over my wacky work-around I had to use to keep "non-called" functions in the code so a function pointer to them can work, so I'll mention that as well.
_________________
Allen C. Huffman, Sub-Etha Software (est. 1990) http://www.subethasoftware.com
Embedded C, Arduino, MSP430, ESP8266/32, BASIC Stamp and PIC24 programmer.
http://www.whywouldyouwanttodothat.com ?

Using: 24FJ256GA106, 24EP256GP202 and 24FJ64GA002.
Ttelmah



Joined: 11 Mar 2010
Posts: 19954

View user's profile Send private message

PostPosted: Thu Sep 25, 2025 1:16 am     Reply with quote

I suspect it is the placement.

This warning is not generated when you #include the file, but when the
compiler gets to the end of the compilation, and 'realises' that the
function is not called. The ignore warnings none line turns the warnings
back on at this point.
Some warnings are immediate. Some are for the whole code/
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group