Skip to content

Commit

Permalink
Use variable only in scope
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiolo committed Sep 21, 2024
1 parent 877f9a3 commit cd6a07a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/text.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,7 @@ struct Text {
wxString htmlify(wxString &str) {
wxString r;
for(auto cref : str) {
wxChar c = cref.GetValue();
switch(c) {
switch (wxChar c = cref.GetValue()) {
case '&': r += L"&"; break;
case '<': r += L"&lt;"; break;
case '>': r += L"&gt;"; break;
Expand Down

0 comments on commit cd6a07a

Please sign in to comment.