File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -154,14 +154,16 @@ void gcc_message_handlert::print(
154154 if (!function.empty ())
155155 {
156156 if (!file.empty ())
157- dest+= id2string (file)+ " :" ;
157+ dest += command ( 1 ) + id2string (file) + " :" + command ( 0 ); // bold
158158 if (dest!=" " )
159159 dest+=' ' ;
160160 dest+=" In function '" +id2string (function)+" ':\n " ;
161161 }
162162
163163 if (!line.empty ())
164164 {
165+ dest += command (1 ); // bold
166+
165167 if (!file.empty ())
166168 dest+=id2string (file)+" :" ;
167169
@@ -173,9 +175,11 @@ void gcc_message_handlert::print(
173175 dest+=id2string (column)+" : " ;
174176
175177 if (level==messaget::M_ERROR)
176- dest+= " error: " ;
178+ dest += command ( 31 ) + " error: " ; // red
177179 else if (level==messaget::M_WARNING)
178- dest+=" warning: " ;
180+ dest += command (95 ) + " warning: " ; // bright magenta
181+
182+ dest += command (0 ); // reset
179183 }
180184
181185 dest+=message;
Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ class console_message_handlert : public message_handlert
5454 bool use_SGR;
5555};
5656
57- class gcc_message_handlert : public message_handlert
57+ class gcc_message_handlert : public console_message_handlert
5858{
5959public:
6060 // aims to imitate the messages gcc prints
You can’t perform that action at this time.
0 commit comments