mirror of
https://github.com/mre/mos6502.git
synced 2024-11-28 07:49:19 +00:00
Upgrade to Rust 2018 edition
This commit is contained in:
parent
b6e4a5ce8b
commit
24973d7fbd
@ -34,6 +34,7 @@ version = "0.2.0"
|
||||
authors = ["The 6502-rs Developers"]
|
||||
build = "build.rs"
|
||||
exclude = ["examples/**"]
|
||||
edition = "2018"
|
||||
|
||||
[lib]
|
||||
# This will look in src/lib.rs
|
||||
|
@ -17,7 +17,6 @@ use mos6502::address::Address;
|
||||
use mos6502::cpu;
|
||||
|
||||
fn main() {
|
||||
|
||||
let zero_page_data = [56, 49];
|
||||
|
||||
let program = [
|
||||
@ -51,6 +50,5 @@ fn main() {
|
||||
cpu.run();
|
||||
|
||||
assert_eq!(7, cpu.registers.accumulator);
|
||||
|
||||
}
|
||||
```
|
||||
|
@ -25,11 +25,10 @@
|
||||
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
// POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
use address::{Address, AddressDiff};
|
||||
use instruction;
|
||||
use instruction::{DecodedInstr, Instruction, OpInput};
|
||||
use memory::Memory;
|
||||
use registers::{Registers, StackPointer, Status, StatusArgs};
|
||||
use crate::address::{Address, AddressDiff};
|
||||
use crate::instruction::{self, DecodedInstr, Instruction, OpInput};
|
||||
use crate::memory::Memory;
|
||||
use crate::registers::{Registers, StackPointer, Status, StatusArgs};
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct CPU {
|
||||
|
@ -25,9 +25,9 @@
|
||||
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
// POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
use address::Address;
|
||||
use address::AddressDiff;
|
||||
use cpu::CPU;
|
||||
use crate::address::Address;
|
||||
use crate::address::AddressDiff;
|
||||
use crate::cpu::CPU;
|
||||
|
||||
// Abbreviations
|
||||
//
|
||||
|
@ -25,7 +25,7 @@
|
||||
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
// POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
use address::{Address, AddressDiff};
|
||||
use crate::address::{Address, AddressDiff};
|
||||
|
||||
// JAM: We can probably come up with a better way to represent address ranges.
|
||||
// Address range type?
|
||||
|
@ -25,8 +25,8 @@
|
||||
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
// POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
use address::{Address, AddressDiff};
|
||||
use memory::{STACK_ADDRESS_HI, STACK_ADDRESS_LO};
|
||||
use crate::address::{Address, AddressDiff};
|
||||
use crate::memory::{STACK_ADDRESS_HI, STACK_ADDRESS_LO};
|
||||
|
||||
// Useful for constructing Status instances
|
||||
#[derive(Copy, Clone)]
|
||||
|
Loading…
Reference in New Issue
Block a user