Skip to content

Commit

Permalink
Eliminate dead code to placate GCC 7's -Wformat-truncation.
Browse files Browse the repository at this point in the history
  • Loading branch information
cgull committed Feb 1, 2017
1 parent a993c83 commit c1d85f0
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 15 deletions.
13 changes: 0 additions & 13 deletions src/terminal/parseraction.cc
Expand Up @@ -38,19 +38,6 @@

using namespace Parser;

std::string Action::str( void )
{
char thechar[ 10 ] = { 0 };
if ( char_present ) {
if ( iswprint( ch ) )
snprintf( thechar, 10, "(%lc)", static_cast<wint_t>(ch) );
else
snprintf( thechar, 10, "(0x%x)", static_cast<unsigned int>(ch) );
}

return name() + std::string( thechar );
}

void Print::act_on_terminal( Terminal::Emulator *emu ) const
{
emu->print( this );
Expand Down
2 changes: 0 additions & 2 deletions src/terminal/parseraction.h
Expand Up @@ -47,8 +47,6 @@ namespace Parser {
wchar_t ch;
bool char_present;

std::string str( void );

virtual std::string name( void ) = 0;

virtual void act_on_terminal( Terminal::Emulator * ) const {};
Expand Down

0 comments on commit c1d85f0

Please sign in to comment.