diff options
author | 2010-06-08 17:35:49 +0000 | |
---|---|---|
committer | 2010-06-08 17:35:49 +0000 | |
commit | 5e04468569256d7b9cc1b6069f9c46c90e2455be (patch) | |
tree | 6e00da715aa56ac59d107f6c3f7b8058362da5b0 /src/emu/cpu/pdp1 | |
parent | d1e9200589119fa135ffd5801dd018ead4865c23 (diff) |
Changed CPU callbacks to use cpu_device, eliminating a bunch of casting.
Diffstat (limited to 'src/emu/cpu/pdp1')
-rw-r--r-- | src/emu/cpu/pdp1/pdp1.c | 6 | ||||
-rw-r--r-- | src/emu/cpu/pdp1/tx0.c | 10 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/emu/cpu/pdp1/pdp1.c b/src/emu/cpu/pdp1/pdp1.c index 82ee77aa82b..90e5c57038d 100644 --- a/src/emu/cpu/pdp1/pdp1.c +++ b/src/emu/cpu/pdp1/pdp1.c @@ -417,7 +417,7 @@ struct _pdp1_state /* 1 for 16-line sequence break system, 0 for default break system */ int type_20_sbs; - running_device *device; + cpu_device *device; const address_space *program; int icount; }; @@ -545,7 +545,7 @@ static CPU_INIT( pdp1 ) /* clean-up */ memset (cpustate, 0, sizeof (*cpustate)); cpustate->device = device; - cpustate->program = device_memory(device)->space(AS_PROGRAM); + cpustate->program = device->space(AS_PROGRAM); /* set up params and callbacks */ for (i=0; i<64; i++) @@ -936,7 +936,7 @@ static CPU_SET_INFO( pdp1 ) CPU_GET_INFO( pdp1 ) { - pdp1_state *cpustate = (device != NULL && downcast<cpu_device *>(device)->token() != NULL) ? get_safe_token(device) : NULL; + pdp1_state *cpustate = (device != NULL && device->token() != NULL) ? get_safe_token(device) : NULL; switch (state) { diff --git a/src/emu/cpu/pdp1/tx0.c b/src/emu/cpu/pdp1/tx0.c index 29f925f5e74..4325a03e057 100644 --- a/src/emu/cpu/pdp1/tx0.c +++ b/src/emu/cpu/pdp1/tx0.c @@ -64,7 +64,7 @@ struct _tx0_state int icount; - running_device *device; + cpu_device *device; const address_space *program; }; @@ -126,7 +126,7 @@ static void tx0_write(tx0_state *cpustate, offs_t address, int data) ; } -static void tx0_init_common(running_device *device, device_irq_callback irqcallback, int is_64kw) +static void tx0_init_common(cpu_device *device, device_irq_callback irqcallback, int is_64kw) { tx0_state *cpustate = get_safe_token(device); @@ -137,7 +137,7 @@ static void tx0_init_common(running_device *device, device_irq_callback irqcallb cpustate->ir_mask = is_64kw ? 03 : 037; cpustate->device = device; - cpustate->program = device_memory(device)->space(AS_PROGRAM); + cpustate->program = device->space(AS_PROGRAM); } static CPU_INIT( tx0_64kw ) @@ -434,7 +434,7 @@ static CPU_SET_INFO( tx0 ) CPU_GET_INFO( tx0_64kw ) { - tx0_state *cpustate = ( device != NULL && downcast<cpu_device *>(device)->token() != NULL ) ? get_safe_token(device) : NULL; + tx0_state *cpustate = ( device != NULL && device->token() != NULL ) ? get_safe_token(device) : NULL; switch (state) { @@ -560,7 +560,7 @@ CPU_GET_INFO( tx0_64kw ) CPU_GET_INFO( tx0_8kw ) { - tx0_state *cpustate = ( device != NULL && downcast<cpu_device *>(device)->token() != NULL ) ? get_safe_token(device) : NULL; + tx0_state *cpustate = ( device != NULL && device->token() != NULL ) ? get_safe_token(device) : NULL; switch (state) { |