From e2a449dfc70d6791918506013776600a5c5f86e6 Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Wed, 26 Dec 2018 16:14:35 +0100 Subject: Change link representation again, make it a plain map. --- src/main.rs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/main.rs b/src/main.rs index 2287575..c56ffb3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -47,7 +47,7 @@ struct Mark { name: String, alternative_names: Vec, symbols: Vec, - links: Vec>, + links: BTreeMap, } struct Primstav { @@ -70,10 +70,8 @@ fn print_entry(m: &Mark) { if !m.links.is_empty() { println!("Kilder:"); - for l in &m.links { - for (source, url) in l.iter() { - println!(" {}: {}", source, url); - } + for (source, url) in m.links.iter() { + println!(" {}: {}", source, url); } } } -- cgit v1.2.3