summaryrefslogtreecommitdiff
path: root/abnf_to_pest/src
diff options
context:
space:
mode:
authorNadrieril2019-04-15 17:33:32 +0200
committerNadrieril2019-04-15 17:33:32 +0200
commit52615794bfe69a3ad14bff0044ade776028c08cd (patch)
tree927b8816493cc534281269199d1f8983c5d5626f /abnf_to_pest/src
parent63aa21c581933a10b2b1ab96c632c72834cf2115 (diff)
Use upstream abnf crate
Diffstat (limited to 'abnf_to_pest/src')
-rw-r--r--abnf_to_pest/src/lib.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/abnf_to_pest/src/lib.rs b/abnf_to_pest/src/lib.rs
index 1b8fc9c..46bd79d 100644
--- a/abnf_to_pest/src/lib.rs
+++ b/abnf_to_pest/src/lib.rs
@@ -110,8 +110,8 @@ pub fn escape_rulename(x: &str) -> String {
}
}
-fn format_char(x: usize) -> String {
- if x <= usize::from(u8::max_value()) {
+fn format_char(x: u32) -> String {
+ if x <= u32::from(u8::max_value()) {
let x: u8 = x as u8;
if x.is_ascii_graphic() {
let x: char = x as char;