mirror of
https://github.com/TomHarte/CLK.git
synced 2025-08-09 05:25:01 +00:00
Avoid undefined behaviour on left shift.
This commit is contained in:
@@ -8,9 +8,11 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
namespace TargetPlatform {
|
||||
|
||||
using IntType = int;
|
||||
using IntType = uint32_t;
|
||||
|
||||
constexpr IntType bit(int index) {
|
||||
return 1 << index;
|
||||
@@ -56,7 +58,7 @@ enum Type: IntType {
|
||||
AllDisk = Acorn | Commodore | AmstradCPC | C64 | Oric | MSX | ZXSpectrum | Macintosh | AtariST | DiskII | PCCompatible | FAT12,
|
||||
AllTape = Acorn | AmstradCPC | Commodore8bit | Oric | ZX8081 | MSX | ZXSpectrum,
|
||||
|
||||
All = ~0,
|
||||
All = ~IntType(0),
|
||||
};
|
||||
|
||||
class Distinguisher {
|
||||
|
Reference in New Issue
Block a user