@@ -576,7 +576,7 @@ launchExec cFileOpts execOpts cExecOpts cOpts = do
576576vmFromCommand :: CommonOptions -> CommonExecOptions -> CommonFileOptions -> ExecOptions -> IO (VM Concrete RealWorld )
577577vmFromCommand cOpts cExecOpts cFileOpts execOpts= do
578578 (miner,ts,baseFee,blockNum,prevRan) <- case cExecOpts. rpc of
579- Nothing -> pure (LitAddr 0 ,Lit 0 ,0 ,0 ,0 )
579+ Nothing -> pure (LitAddr 0 ,Lit 0 ,0 ,Lit 0 ,0 )
580580 Just url -> Fetch. fetchBlockFrom block url >>= \ case
581581 Nothing -> do
582582 putStrLn $ " Error, Could not fetch block" <> show block <> " from URL: " <> show url
@@ -665,7 +665,7 @@ vmFromCommand cOpts cExecOpts cFileOpts execOpts= do
665665 , priorityFee = word (. priorityFee) 0
666666 , gaslimit = word64 (. gaslimit) 0xffffffffffffffff
667667 , coinbase = addr (. coinbase) miner
668- , number = word ( . number) blockNum
668+ , number = maybe blockNum Lit cExecOpts . number
669669 , timestamp = Lit $ word (. timestamp) ts
670670 , blockGaslimit = word64 (. gaslimit) 0xffffffffffffffff
671671 , gasprice = word (. gasprice) 0
@@ -688,7 +688,7 @@ vmFromCommand cOpts cExecOpts cFileOpts execOpts= do
688688symvmFromCommand :: CommonExecOptions -> SymbolicOptions -> CommonFileOptions -> (Expr Buf , [Prop ]) -> IO (VM EVM.Types. Symbolic RealWorld )
689689symvmFromCommand cExecOpts sOpts cFileOpts calldata = do
690690 (miner,blockNum,baseFee,prevRan) <- case cExecOpts. rpc of
691- Nothing -> pure (SymAddr " miner" ,0 ,0 ,0 )
691+ Nothing -> pure (SymAddr " miner" ,Lit 0 ,0 ,0 )
692692 Just url -> Fetch. fetchBlockFrom block url >>= \ case
693693 Nothing -> do
694694 putStrLn $ " Error, Could not fetch block" <> show block <> " from URL: " <> show url
@@ -765,7 +765,7 @@ symvmFromCommand cExecOpts sOpts cFileOpts calldata = do
765765 , baseFee = baseFee
766766 , priorityFee = word (. priorityFee) 0
767767 , coinbase = eaddr (. coinbase) miner
768- , number = word ( . number) blockNum
768+ , number = maybe blockNum Lit cExecOpts . number
769769 , timestamp = ts
770770 , blockGaslimit = word64 (. gaslimit) 0xffffffffffffffff
771771 , gasprice = word (. gasprice) 0
0 commit comments