Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Commit

Permalink
Merge pull request #1406 from ethcore/jit
Browse files Browse the repository at this point in the history
Fixing jit compilation
  • Loading branch information
NikVolf authored Jun 23, 2016
2 parents 082294f + 1958594 commit 1d31cee
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions ethcore/src/evm/jit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@

//! Just in time compiler execution environment.
use common::*;
use trace::VMTracer;
use evmjit;
use evm::{self, Error, GasLeft};
use evm::{self, GasLeft};

/// Should be used to convert jit types to ethcore
trait FromJit<T>: Sized {
Expand Down Expand Up @@ -303,7 +302,7 @@ impl<'a> evmjit::Ext for ExtAdapter<'a> {

#[derive(Default)]
pub struct JitEvm {
ctxt: Option<evmjit::ContextHandle>,
context: Option<evmjit::ContextHandle>,
}

impl evm::Evm for JitEvm {
Expand Down Expand Up @@ -347,7 +346,7 @@ impl evm::Evm for JitEvm {
data.timestamp = ext.env_info().timestamp as i64;

self.context = Some(unsafe { evmjit::ContextHandle::new(data, schedule, &mut ext_handle) });
let context = self.context.as_ref_mut().unwrap();
let mut context = self.context.as_mut().unwrap();
let res = context.exec();

match res {
Expand Down

0 comments on commit 1d31cee

Please sign in to comment.