From b2afafa4104817e56292d2d80d965b6d9ac445e1 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 25 Jan 2016 08:46:46 +0100 Subject: loplugin:cstylecast Change-Id: Ie2aeedac1b3fd90d6302be6e5917e99a782d76c7 --- comphelper/qa/container/testifcontainer.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'comphelper') diff --git a/comphelper/qa/container/testifcontainer.cxx b/comphelper/qa/container/testifcontainer.cxx index 7533695640d0..98bced110d53 100644 --- a/comphelper/qa/container/testifcontainer.cxx +++ b/comphelper/qa/container/testifcontainer.cxx @@ -79,7 +79,7 @@ void test_interfacecontainer() OInterfaceIteratorHelper iterator( helper ); while( iterator.hasMoreElements() ) - ((XVetoableChangeListener*)iterator.next())->vetoableChange( PropertyChangeEvent() ); + static_cast(iterator.next())->vetoableChange( PropertyChangeEvent() ); helper.disposeAndClear( EventObject() ); } @@ -97,11 +97,11 @@ void test_interfacecontainer() OInterfaceIteratorHelper iterator( helper ); - ((XVetoableChangeListener*)iterator.next())->vetoableChange( PropertyChangeEvent() ); + static_cast(iterator.next())->vetoableChange( PropertyChangeEvent() ); iterator.remove(); - ((XVetoableChangeListener*)iterator.next())->vetoableChange( PropertyChangeEvent() ); + static_cast(iterator.next())->vetoableChange( PropertyChangeEvent() ); iterator.remove(); - ((XVetoableChangeListener*)iterator.next())->vetoableChange( PropertyChangeEvent() ); + static_cast(iterator.next())->vetoableChange( PropertyChangeEvent() ); iterator.remove(); OSL_ASSERT( helper.getLength() == 0 ); @@ -123,7 +123,7 @@ void test_interfacecontainer() OInterfaceIteratorHelper iterator( helper ); while( iterator.hasMoreElements() ) { - Reference< XVetoableChangeListener > r = ((XVetoableChangeListener*)iterator.next()); + Reference< XVetoableChangeListener > r = static_cast(iterator.next()); if( r == r1 ) iterator.remove(); } @@ -133,7 +133,7 @@ void test_interfacecontainer() OInterfaceIteratorHelper iterator( helper ); while( iterator.hasMoreElements() ) { - Reference< XVetoableChangeListener > r = ((XVetoableChangeListener*)iterator.next()); + Reference< XVetoableChangeListener > r = static_cast(iterator.next()); OSL_ASSERT( r != r1 && ( r == r2 || r == r3 ) ); } } -- cgit