Skip to content

Commit

Permalink
[Ref] openmpt123: Older clang has stupid opinions about coding style.…
Browse files Browse the repository at this point in the history
… Use override instead of final, it does not really matter here.

git-svn-id: https://source.openmpt.org/svn/openmpt/trunk/OpenMPT@21708 56274372-70c3-4bfc-bfc3-4c3a0b034d27
  • Loading branch information
manxorist committed Sep 23, 2024
1 parent 72ad623 commit 84233e2
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions openmpt123/openmpt123.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,12 +194,12 @@ class textout : public string_concat_stream<mpt::ustring> {
class textout_dummy : public textout {
public:
textout_dummy() = default;
~textout_dummy() final = default;
~textout_dummy() override = default;
public:
void writeout() final {
void writeout() override {
static_cast<void>( pop() );
}
void cursor_up( std::size_t lines ) final {
void cursor_up( std::size_t lines ) override {
static_cast<void>( lines );
}
};
Expand Down Expand Up @@ -241,9 +241,9 @@ class textout_ostream : public textout_backend {
#endif
return;
}
~textout_ostream() final = default;
~textout_ostream() override = default;
public:
void write( const mpt::ustring & text ) final {
void write( const mpt::ustring & text ) override {
if ( text.length() > 0 ) {
#if MPT_OS_DJGPP
s << mpt::transcode<std::string>( codepage, text );
Expand All @@ -255,7 +255,7 @@ class textout_ostream : public textout_backend {
s.flush();
}
}
void cursor_up( std::size_t lines ) final {
void cursor_up( std::size_t lines ) override {
s.flush();
for ( std::size_t line = 0; line < lines; ++line ) {
s << std::string("\x1b[1A");
Expand All @@ -274,15 +274,15 @@ class textout_wostream : public textout_backend {
{
return;
}
~textout_wostream() final = default;
~textout_wostream() override = default;
public:
void write( const mpt::ustring & text ) final {
void write( const mpt::ustring & text ) override {
if ( text.length() > 0 ) {
s << mpt::transcode<std::wstring>( text );
s.flush();
}
}
void cursor_up( std::size_t lines ) final {
void cursor_up( std::size_t lines ) override {
s.flush();
for ( std::size_t line = 0; line < lines; ++line ) {
s << std::wstring(L"\x1b[1A");
Expand Down Expand Up @@ -315,9 +315,9 @@ class textout_ostream_console : public textout_backend {
{
return;
}
~textout_ostream_console() final = default;
~textout_ostream_console() override = default;
public:
void write( const mpt::ustring & text ) final {
void write( const mpt::ustring & text ) override {
if ( text.length() > 0 ) {
if ( console ) {
DWORD chars_written = 0;
Expand All @@ -338,7 +338,7 @@ class textout_ostream_console : public textout_backend {
}
}
}
void cursor_up( std::size_t lines ) final {
void cursor_up( std::size_t lines ) override {
if ( console ) {
s.flush();
CONSOLE_SCREEN_BUFFER_INFO csbi;
Expand Down Expand Up @@ -378,12 +378,12 @@ class textout_wrapper : public textout {
#endif
public:
textout_wrapper() = default;
~textout_wrapper() final = default;
~textout_wrapper() override = default;
public:
void writeout() final {
void writeout() override {
out.write( pop() );
}
void cursor_up(std::size_t lines) final {
void cursor_up(std::size_t lines) override {
out.cursor_up( lines );
}
};
Expand Down

0 comments on commit 84233e2

Please sign in to comment.