Downgrade some FIXMEs
This commit is contained in:
parent
0c97755813
commit
69bc30b333
|
@ -446,7 +446,7 @@ where
|
||||||
}
|
}
|
||||||
|
|
||||||
// Subtract this from progressive NTs
|
// Subtract this from progressive NTs
|
||||||
// FIXME: May fail to round correctly with minivoters
|
// TODO: May fail to round correctly with minivoters
|
||||||
let invalid_votes = state.exhausted.votes.clone();
|
let invalid_votes = state.exhausted.votes.clone();
|
||||||
let valid_votes = total_ballots - &invalid_votes;
|
let valid_votes = total_ballots - &invalid_votes;
|
||||||
|
|
||||||
|
@ -465,11 +465,11 @@ where
|
||||||
for (i, candidate) in election.candidates.iter().enumerate() {
|
for (i, candidate) in election.candidates.iter().enumerate() {
|
||||||
let count_card = &state.candidates[candidate];
|
let count_card = &state.candidates[candidate];
|
||||||
stage_results[3 + i].push(format!(r#""{}""#, candidate.name));
|
stage_results[3 + i].push(format!(r#""{}""#, candidate.name));
|
||||||
stage_results[3 + i].push(format!(r#"{:.0}"#, count_card.votes)); // FIXME: May fail to round correctly with minivoters
|
stage_results[3 + i].push(format!(r#"{:.0}"#, count_card.votes)); // TODO: May fail to round correctly with minivoters
|
||||||
}
|
}
|
||||||
|
|
||||||
stage_results[3 + election.candidates.len()].push(String::from(r#""Non-transferable""#));
|
stage_results[3 + election.candidates.len()].push(String::from(r#""Non-transferable""#));
|
||||||
stage_results[3 + election.candidates.len()].push(String::new()); // FIXME: May fail to round correctly with minivoters
|
stage_results[3 + election.candidates.len()].push(String::new()); // TODO: May fail to round correctly with minivoters
|
||||||
|
|
||||||
stage_results[4 + election.candidates.len()].push(String::from(r#""Totals""#));
|
stage_results[4 + election.candidates.len()].push(String::from(r#""Totals""#));
|
||||||
stage_results[4 + election.candidates.len()].push(format!(r#"{:.0}"#, valid_votes));
|
stage_results[4 + election.candidates.len()].push(format!(r#"{:.0}"#, valid_votes));
|
||||||
|
|
|
@ -170,8 +170,6 @@ where
|
||||||
tree.descend_tree(&election.candidates);
|
tree.descend_tree(&election.candidates);
|
||||||
}
|
}
|
||||||
|
|
||||||
// FIXME: Possibility of infinite loop if malformed inputs?
|
|
||||||
|
|
||||||
// Credit votes at this level
|
// Credit votes at this level
|
||||||
for (candidate, cand_tree) in tree.next_preferences.as_mut().unwrap().as_mut().iter_mut() {
|
for (candidate, cand_tree) in tree.next_preferences.as_mut().unwrap().as_mut().iter_mut() {
|
||||||
let count_card = candidates.get_mut(candidate).unwrap();
|
let count_card = candidates.get_mut(candidate).unwrap();
|
||||||
|
|
Loading…
Reference in New Issue