Skip to content

Commit

Permalink
1700 clang format
Browse files Browse the repository at this point in the history
  • Loading branch information
kladkogex committed Oct 19, 2023
1 parent 33502b1 commit aad381b
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions libevm/LegacyVM.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
*/

#include "libskale/PushZeroPatch.h"
#include "LegacyVM.h"
#include "libskale/PushZeroPatch.h"

using namespace std;
using namespace dev;
Expand All @@ -28,12 +28,12 @@ uint64_t LegacyVM::memNeed( u256 const& _offset, u256 const& _size ) {

template < class S >
S divWorkaround( S const& _a, S const& _b ) {
return ( S )( s512( _a ) / s512( _b ) );
return ( S ) ( s512( _a ) / s512( _b ) );
}

template < class S >
S modWorkaround( S const& _a, S const& _b ) {
return ( S )( s512( _a ) % s512( _b ) );
return ( S ) ( s512( _a ) % s512( _b ) );
}


Expand Down Expand Up @@ -354,7 +354,7 @@ void LegacyVM::interpretCases() {
updateMem( toInt63( m_SP[0] ) + 1 );
updateIOGas();

m_mem[( unsigned ) m_SP[0]] = ( _byte_ )( m_SP[1] & 0xff );
m_mem[( unsigned ) m_SP[0]] = ( _byte_ ) ( m_SP[1] & 0xff );
}
NEXT

Expand Down Expand Up @@ -1083,7 +1083,9 @@ void LegacyVM::interpretCases() {
CASE( XPUT )
CASE( XGET )
CASE( XSWIZZLE )
CASE( XSHUFFLE ) { throwBadInstruction(); }
CASE( XSHUFFLE ) {
throwBadInstruction();
}
CONTINUE
#endif

Expand Down Expand Up @@ -1360,7 +1362,7 @@ void LegacyVM::interpretCases() {
// we need to increment program counter only by one since
// the value is not read from program code as in PUSH1
CASE( PUSH0 ) {
if (!PushZeroPatch::isEnabled()) {
if ( !PushZeroPatch::isEnabled() ) {
throwBadInstruction();
}
ON_OP();
Expand Down

0 comments on commit aad381b

Please sign in to comment.