Store UNICODE_VERSION as a tuple

Remove the UnicodeVersion struct containing
major, minor and update fields and replace it with
a 3-tuple containing the version number.
As the value of each field is limited to 255
use u8 to store them.
This commit is contained in:
Pyfisch
2020-04-11 12:56:25 +02:00
parent 1f3b65921e
commit 7f4048c710
6 changed files with 8 additions and 33 deletions

View File

@@ -295,7 +295,7 @@ fn main() {
fn version() -> String {
let mut out = String::new();
out.push_str("pub const UNICODE_VERSION: (u32, u32, u32) = ");
out.push_str("pub const UNICODE_VERSION: (u8, u8, u8) = ");
let readme =
std::fs::read_to_string(std::path::Path::new(UNICODE_DIRECTORY).join("ReadMe.txt"))