Sorry, I guess I meant 'I as the programmer could use the SEGMENT command'. I didn't intend to say you can use it to solve your own error.
I'm not acquainted with CCSv4. I don't know for sure that CCSv4 has a command which fixes your code size limit error.
I remember I would get a similar error using FutureBasic. Looking through the manual I saw that I needed to insert the 'SEGMENT' command to fix the error. I imagine it had to do with adding a second block of memory for jump tables, etc.
Some error messages are not always caused by exactly what the message tells you. Besides the size of your program itself, a code size error might refer to memory being full, or insufficient blocks of memory being available for additional:
simple variables,
array variables,
string variables,
number of subroutines/functions,
number of calls to routines,
recursive loops (routines which call themselves, whether intended or not),
number of opened ports, inputs, outputs,
size or number of buffers allocated for input/output
etc.