2338 lines
111 KiB
JSON
2338 lines
111 KiB
JSON
[
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace expand with ()\n@@ -8,34 +8,17 @@\n pub const MAX_FIELD: usize = 2_000;\n /// Finishing orders drawn for a sampled field.\n pub const SAMPLES: u32 = 20_000;\n /// Fixed, so the same field gives the same equities and two fields are compared on the same\n /// draws (common random numbers keep the difference of two evaluations smooth).\n const SAMPLE_SEED: u64 = 0x1C4_5EED;\n \n fn expand(stacks: &[f64], taken: &mut Vec<usize>, probability: f64, payouts: &[f64], out: &mut [f64]) {\n- let place = taken.len();\n- if place >= payouts.len() || probability <= 0.0 {\n- return;\n- }\n- let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n- if left <= 0.0 {\n- return;\n- }\n- for i in 0..stacks.len() {\n- if taken.contains(&i) {\n- continue;\n- }\n- let p = probability * stacks[i] / left;\n- out[i] += p * payouts[place];\n- taken.push(i);\n- expand(stacks, taken, p, payouts, out);\n- taken.pop();\n- }\n+ () /* ~ changed by cargo-mutants ~ */\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n if stacks.len() > MAX_PLAYERS {\n return sampled_equities(stacks, payouts);\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:16:5: replace expand with ()",
|
|
"package": "pokerfreak",
|
|
"replacement": "()",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 33
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 16
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace || with && in expand\n@@ -9,17 +9,17 @@\n /// Finishing orders drawn for a sampled field.\n pub const SAMPLES: u32 = 20_000;\n /// Fixed, so the same field gives the same equities and two fields are compared on the same\n /// draws (common random numbers keep the difference of two evaluations smooth).\n const SAMPLE_SEED: u64 = 0x1C4_5EED;\n \n fn expand(stacks: &[f64], taken: &mut Vec<usize>, probability: f64, payouts: &[f64], out: &mut [f64]) {\n let place = taken.len();\n- if place >= payouts.len() || probability <= 0.0 {\n+ if place >= payouts.len() && /* ~ changed by cargo-mutants ~ */ probability <= 0.0 {\n return;\n }\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:17:31: replace || with && in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "&&",
|
|
"span": {
|
|
"end": {
|
|
"column": 33,
|
|
"line": 17
|
|
},
|
|
"start": {
|
|
"column": 31,
|
|
"line": 17
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace >= with < in expand\n@@ -9,17 +9,17 @@\n /// Finishing orders drawn for a sampled field.\n pub const SAMPLES: u32 = 20_000;\n /// Fixed, so the same field gives the same equities and two fields are compared on the same\n /// draws (common random numbers keep the difference of two evaluations smooth).\n const SAMPLE_SEED: u64 = 0x1C4_5EED;\n \n fn expand(stacks: &[f64], taken: &mut Vec<usize>, probability: f64, payouts: &[f64], out: &mut [f64]) {\n let place = taken.len();\n- if place >= payouts.len() || probability <= 0.0 {\n+ if place < /* ~ changed by cargo-mutants ~ */ payouts.len() || probability <= 0.0 {\n return;\n }\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:17:14: replace >= with < in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "<",
|
|
"span": {
|
|
"end": {
|
|
"column": 16,
|
|
"line": 17
|
|
},
|
|
"start": {
|
|
"column": 14,
|
|
"line": 17
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace <= with > in expand\n@@ -9,17 +9,17 @@\n /// Finishing orders drawn for a sampled field.\n pub const SAMPLES: u32 = 20_000;\n /// Fixed, so the same field gives the same equities and two fields are compared on the same\n /// draws (common random numbers keep the difference of two evaluations smooth).\n const SAMPLE_SEED: u64 = 0x1C4_5EED;\n \n fn expand(stacks: &[f64], taken: &mut Vec<usize>, probability: f64, payouts: &[f64], out: &mut [f64]) {\n let place = taken.len();\n- if place >= payouts.len() || probability <= 0.0 {\n+ if place >= payouts.len() || probability > /* ~ changed by cargo-mutants ~ */ 0.0 {\n return;\n }\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:17:46: replace <= with > in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": ">",
|
|
"span": {
|
|
"end": {
|
|
"column": 48,
|
|
"line": 17
|
|
},
|
|
"start": {
|
|
"column": 46,
|
|
"line": 17
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ delete ! in expand\n@@ -12,17 +12,17 @@\n /// draws (common random numbers keep the difference of two evaluations smooth).\n const SAMPLE_SEED: u64 = 0x1C4_5EED;\n \n fn expand(stacks: &[f64], taken: &mut Vec<usize>, probability: f64, payouts: &[f64], out: &mut [f64]) {\n let place = taken.len();\n if place >= payouts.len() || probability <= 0.0 {\n return;\n }\n- let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n+ let left: f64 = stacks.iter().enumerate().filter(|(i, _)| /* ~ changed by cargo-mutants ~ */taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n let p = probability * stacks[i] / left;\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "UnaryOperator",
|
|
"name": "src/icm/harville.rs:20:63: delete ! in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 64,
|
|
"line": 20
|
|
},
|
|
"start": {
|
|
"column": 63,
|
|
"line": 20
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace <= with > in expand\n@@ -13,17 +13,17 @@\n const SAMPLE_SEED: u64 = 0x1C4_5EED;\n \n fn expand(stacks: &[f64], taken: &mut Vec<usize>, probability: f64, payouts: &[f64], out: &mut [f64]) {\n let place = taken.len();\n if place >= payouts.len() || probability <= 0.0 {\n return;\n }\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n- if left <= 0.0 {\n+ if left > /* ~ changed by cargo-mutants ~ */ 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n let p = probability * stacks[i] / left;\n out[i] += p * payouts[place];\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:21:13: replace <= with > in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": ">",
|
|
"span": {
|
|
"end": {
|
|
"column": 15,
|
|
"line": 21
|
|
},
|
|
"start": {
|
|
"column": 13,
|
|
"line": 21
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace / with % in expand\n@@ -20,17 +20,17 @@\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n- let p = probability * stacks[i] / left;\n+ let p = probability * stacks[i] % /* ~ changed by cargo-mutants ~ */ left;\n out[i] += p * payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:28:41: replace / with % in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "%",
|
|
"span": {
|
|
"end": {
|
|
"column": 42,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 41,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace / with * in expand\n@@ -20,17 +20,17 @@\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n- let p = probability * stacks[i] / left;\n+ let p = probability * stacks[i] * /* ~ changed by cargo-mutants ~ */ left;\n out[i] += p * payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:28:41: replace / with * in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "*",
|
|
"span": {
|
|
"end": {
|
|
"column": 42,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 41,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace * with + in expand\n@@ -20,17 +20,17 @@\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n- let p = probability * stacks[i] / left;\n+ let p = probability + /* ~ changed by cargo-mutants ~ */ stacks[i] / left;\n out[i] += p * payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:28:29: replace * with + in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "+",
|
|
"span": {
|
|
"end": {
|
|
"column": 30,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 29,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace * with / in expand\n@@ -20,17 +20,17 @@\n let left: f64 = stacks.iter().enumerate().filter(|(i, _)| !taken.contains(i)).map(|(_, s)| *s).sum();\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n- let p = probability * stacks[i] / left;\n+ let p = probability / /* ~ changed by cargo-mutants ~ */ stacks[i] / left;\n out[i] += p * payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:28:29: replace * with / in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "/",
|
|
"span": {
|
|
"end": {
|
|
"column": 30,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 29,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace += with -= in expand\n@@ -21,17 +21,17 @@\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n let p = probability * stacks[i] / left;\n- out[i] += p * payouts[place];\n+ out[i] -= /* ~ changed by cargo-mutants ~ */ p * payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:29:16: replace += with -= in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "-=",
|
|
"span": {
|
|
"end": {
|
|
"column": 18,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 16,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace += with *= in expand\n@@ -21,17 +21,17 @@\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n let p = probability * stacks[i] / left;\n- out[i] += p * payouts[place];\n+ out[i] *= /* ~ changed by cargo-mutants ~ */ p * payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:29:16: replace += with *= in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "*=",
|
|
"span": {
|
|
"end": {
|
|
"column": 18,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 16,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace * with + in expand\n@@ -21,17 +21,17 @@\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n let p = probability * stacks[i] / left;\n- out[i] += p * payouts[place];\n+ out[i] += p + /* ~ changed by cargo-mutants ~ */ payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:29:21: replace * with + in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "+",
|
|
"span": {
|
|
"end": {
|
|
"column": 22,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 21,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace * with / in expand\n@@ -21,17 +21,17 @@\n if left <= 0.0 {\n return;\n }\n for i in 0..stacks.len() {\n if taken.contains(&i) {\n continue;\n }\n let p = probability * stacks[i] / left;\n- out[i] += p * payouts[place];\n+ out[i] += p / /* ~ changed by cargo-mutants ~ */ payouts[place];\n taken.push(i);\n expand(stacks, taken, p, payouts, out);\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "expand",
|
|
"return_type": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 34
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:29:21: replace * with / in expand",
|
|
"package": "pokerfreak",
|
|
"replacement": "/",
|
|
"span": {
|
|
"end": {
|
|
"column": 22,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 21,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace equities -> Vec<f64> with vec![]\n@@ -32,23 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n- return sampled_equities(stacks, payouts);\n- }\n- let mut out = vec![0.0; stacks.len()];\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n- out\n+ vec![] /* ~ changed by cargo-mutants ~ */\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n let paid = &payouts[..payouts.len().min(stacks.len())];\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:40:5: replace equities -> Vec<f64> with vec![]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![]",
|
|
"span": {
|
|
"end": {
|
|
"column": 8,
|
|
"line": 46
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace equities -> Vec<f64> with vec![0.0]\n@@ -32,23 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n- return sampled_equities(stacks, payouts);\n- }\n- let mut out = vec![0.0; stacks.len()];\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n- out\n+ vec![0.0] /* ~ changed by cargo-mutants ~ */\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n let paid = &payouts[..payouts.len().min(stacks.len())];\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:40:5: replace equities -> Vec<f64> with vec![0.0]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![0.0]",
|
|
"span": {
|
|
"end": {
|
|
"column": 8,
|
|
"line": 46
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace equities -> Vec<f64> with vec![1.0]\n@@ -32,23 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n- return sampled_equities(stacks, payouts);\n- }\n- let mut out = vec![0.0; stacks.len()];\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n- out\n+ vec![1.0] /* ~ changed by cargo-mutants ~ */\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n let paid = &payouts[..payouts.len().min(stacks.len())];\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:40:5: replace equities -> Vec<f64> with vec![1.0]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![1.0]",
|
|
"span": {
|
|
"end": {
|
|
"column": 8,
|
|
"line": 46
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace equities -> Vec<f64> with vec![-1.0]\n@@ -32,23 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n- return sampled_equities(stacks, payouts);\n- }\n- let mut out = vec![0.0; stacks.len()];\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n- out\n+ vec![-1.0] /* ~ changed by cargo-mutants ~ */\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n let paid = &payouts[..payouts.len().min(stacks.len())];\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:40:5: replace equities -> Vec<f64> with vec![-1.0]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![-1.0]",
|
|
"span": {
|
|
"end": {
|
|
"column": 8,
|
|
"line": 46
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace > with == in equities\n@@ -32,17 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n+ if stacks.len() == /* ~ changed by cargo-mutants ~ */ MAX_PLAYERS {\n return sampled_equities(stacks, payouts);\n }\n let mut out = vec![0.0; stacks.len()];\n let paid = &payouts[..payouts.len().min(stacks.len())];\n expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n out\n }\n \n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:40:21: replace > with == in equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "==",
|
|
"span": {
|
|
"end": {
|
|
"column": 22,
|
|
"line": 40
|
|
},
|
|
"start": {
|
|
"column": 21,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace > with < in equities\n@@ -32,17 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n+ if stacks.len() < /* ~ changed by cargo-mutants ~ */ MAX_PLAYERS {\n return sampled_equities(stacks, payouts);\n }\n let mut out = vec![0.0; stacks.len()];\n let paid = &payouts[..payouts.len().min(stacks.len())];\n expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n out\n }\n \n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:40:21: replace > with < in equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "<",
|
|
"span": {
|
|
"end": {
|
|
"column": 22,
|
|
"line": 40
|
|
},
|
|
"start": {
|
|
"column": 21,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace > with >= in equities\n@@ -32,17 +32,17 @@\n taken.pop();\n }\n }\n \n /// Expected prize per player. Places beyond the paid ones pay nothing; more payouts than\n /// players are cut to the field. The sum of the result is the sum of the paid prizes.\n /// Exact up to `MAX_PLAYERS`, sampled above.\n pub fn equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- if stacks.len() > MAX_PLAYERS {\n+ if stacks.len() >= /* ~ changed by cargo-mutants ~ */ MAX_PLAYERS {\n return sampled_equities(stacks, payouts);\n }\n let mut out = vec![0.0; stacks.len()];\n let paid = &payouts[..payouts.len().min(stacks.len())];\n expand(stacks, &mut Vec::new(), 1.0, paid, &mut out);\n out\n }\n \n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:40:21: replace > with >= in equities",
|
|
"package": "pokerfreak",
|
|
"replacement": ">=",
|
|
"span": {
|
|
"end": {
|
|
"column": 22,
|
|
"line": 40
|
|
},
|
|
"start": {
|
|
"column": 21,
|
|
"line": 40
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace sampled_equities -> Vec<f64> with vec![]\n@@ -46,30 +46,10 @@\n out\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- let by_time = |a: &(f64, usize), b: &(f64, usize)| a.0.total_cmp(&b.0);\n- let mut out = vec![0.0; stacks.len()];\n- let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n- let mut rng = Rng::seeded(SAMPLE_SEED);\n- for _ in 0..SAMPLES {\n- times.clear();\n- for (i, stack) in stacks.iter().enumerate() {\n- let (u, next) = rng.unit();\n- rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n- }\n- if paid.len() < times.len() {\n- times.select_nth_unstable_by(paid.len(), by_time);\n- }\n- times[..paid.len()].sort_unstable_by(by_time);\n- for ((_, player), prize) in times.iter().zip(paid) {\n- out[*player] += prize;\n- }\n- }\n- out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n+ vec![] /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:54:5: replace sampled_equities -> Vec<f64> with vec![]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![]",
|
|
"span": {
|
|
"end": {
|
|
"column": 57,
|
|
"line": 74
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 54
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace sampled_equities -> Vec<f64> with vec![0.0]\n@@ -46,30 +46,10 @@\n out\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- let by_time = |a: &(f64, usize), b: &(f64, usize)| a.0.total_cmp(&b.0);\n- let mut out = vec![0.0; stacks.len()];\n- let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n- let mut rng = Rng::seeded(SAMPLE_SEED);\n- for _ in 0..SAMPLES {\n- times.clear();\n- for (i, stack) in stacks.iter().enumerate() {\n- let (u, next) = rng.unit();\n- rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n- }\n- if paid.len() < times.len() {\n- times.select_nth_unstable_by(paid.len(), by_time);\n- }\n- times[..paid.len()].sort_unstable_by(by_time);\n- for ((_, player), prize) in times.iter().zip(paid) {\n- out[*player] += prize;\n- }\n- }\n- out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n+ vec![0.0] /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:54:5: replace sampled_equities -> Vec<f64> with vec![0.0]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![0.0]",
|
|
"span": {
|
|
"end": {
|
|
"column": 57,
|
|
"line": 74
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 54
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace sampled_equities -> Vec<f64> with vec![1.0]\n@@ -46,30 +46,10 @@\n out\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- let by_time = |a: &(f64, usize), b: &(f64, usize)| a.0.total_cmp(&b.0);\n- let mut out = vec![0.0; stacks.len()];\n- let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n- let mut rng = Rng::seeded(SAMPLE_SEED);\n- for _ in 0..SAMPLES {\n- times.clear();\n- for (i, stack) in stacks.iter().enumerate() {\n- let (u, next) = rng.unit();\n- rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n- }\n- if paid.len() < times.len() {\n- times.select_nth_unstable_by(paid.len(), by_time);\n- }\n- times[..paid.len()].sort_unstable_by(by_time);\n- for ((_, player), prize) in times.iter().zip(paid) {\n- out[*player] += prize;\n- }\n- }\n- out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n+ vec![1.0] /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:54:5: replace sampled_equities -> Vec<f64> with vec![1.0]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![1.0]",
|
|
"span": {
|
|
"end": {
|
|
"column": 57,
|
|
"line": 74
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 54
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace sampled_equities -> Vec<f64> with vec![-1.0]\n@@ -46,30 +46,10 @@\n out\n }\n \n \n /// Harville by sampling: the finishing order of an exponential race with rate `stack` has\n /// exactly the Harville law (first is `stack / sum`, then again among the rest). Every stack\n /// must be positive. Deterministic; the sum of the result is the sum of the paid prizes.\n pub fn sampled_equities(stacks: &[f64], payouts: &[f64]) -> Vec<f64> {\n- let paid = &payouts[..payouts.len().min(stacks.len())];\n- let by_time = |a: &(f64, usize), b: &(f64, usize)| a.0.total_cmp(&b.0);\n- let mut out = vec![0.0; stacks.len()];\n- let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n- let mut rng = Rng::seeded(SAMPLE_SEED);\n- for _ in 0..SAMPLES {\n- times.clear();\n- for (i, stack) in stacks.iter().enumerate() {\n- let (u, next) = rng.unit();\n- rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n- }\n- if paid.len() < times.len() {\n- times.select_nth_unstable_by(paid.len(), by_time);\n- }\n- times[..paid.len()].sort_unstable_by(by_time);\n- for ((_, player), prize) in times.iter().zip(paid) {\n- out[*player] += prize;\n- }\n- }\n- out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n+ vec![-1.0] /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/harville.rs:54:5: replace sampled_equities -> Vec<f64> with vec![-1.0]",
|
|
"package": "pokerfreak",
|
|
"replacement": "vec![-1.0]",
|
|
"span": {
|
|
"end": {
|
|
"column": 57,
|
|
"line": 74
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 54
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace / with % in sampled_equities\n@@ -56,17 +56,17 @@\n let mut out = vec![0.0; stacks.len()];\n let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n+ times.push((-(1.0 - u).ln() % /* ~ changed by cargo-mutants ~ */ stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:64:41: replace / with % in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "%",
|
|
"span": {
|
|
"end": {
|
|
"column": 42,
|
|
"line": 64
|
|
},
|
|
"start": {
|
|
"column": 41,
|
|
"line": 64
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace / with * in sampled_equities\n@@ -56,17 +56,17 @@\n let mut out = vec![0.0; stacks.len()];\n let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n+ times.push((-(1.0 - u).ln() * /* ~ changed by cargo-mutants ~ */ stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:64:41: replace / with * in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "*",
|
|
"span": {
|
|
"end": {
|
|
"column": 42,
|
|
"line": 64
|
|
},
|
|
"start": {
|
|
"column": 41,
|
|
"line": 64
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ delete - in sampled_equities\n@@ -56,17 +56,17 @@\n let mut out = vec![0.0; stacks.len()];\n let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n+ times.push(( /* ~ changed by cargo-mutants ~ */(1.0 - u).ln() / stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "UnaryOperator",
|
|
"name": "src/icm/harville.rs:64:25: delete - in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 26,
|
|
"line": 64
|
|
},
|
|
"start": {
|
|
"column": 25,
|
|
"line": 64
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace - with + in sampled_equities\n@@ -56,17 +56,17 @@\n let mut out = vec![0.0; stacks.len()];\n let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n+ times.push((-(1.0 + /* ~ changed by cargo-mutants ~ */ u).ln() / stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:64:31: replace - with + in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "+",
|
|
"span": {
|
|
"end": {
|
|
"column": 32,
|
|
"line": 64
|
|
},
|
|
"start": {
|
|
"column": 31,
|
|
"line": 64
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace - with / in sampled_equities\n@@ -56,17 +56,17 @@\n let mut out = vec![0.0; stacks.len()];\n let mut times: Vec<(f64, usize)> = Vec::with_capacity(stacks.len());\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n- times.push((-(1.0 - u).ln() / stack, i));\n+ times.push((-(1.0 / /* ~ changed by cargo-mutants ~ */ u).ln() / stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:64:31: replace - with / in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "/",
|
|
"span": {
|
|
"end": {
|
|
"column": 32,
|
|
"line": 64
|
|
},
|
|
"start": {
|
|
"column": 31,
|
|
"line": 64
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace < with == in sampled_equities\n@@ -58,17 +58,17 @@\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n times.push((-(1.0 - u).ln() / stack, i));\n }\n- if paid.len() < times.len() {\n+ if paid.len() == /* ~ changed by cargo-mutants ~ */ times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n }\n out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:66:23: replace < with == in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "==",
|
|
"span": {
|
|
"end": {
|
|
"column": 24,
|
|
"line": 66
|
|
},
|
|
"start": {
|
|
"column": 23,
|
|
"line": 66
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace < with > in sampled_equities\n@@ -58,17 +58,17 @@\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n times.push((-(1.0 - u).ln() / stack, i));\n }\n- if paid.len() < times.len() {\n+ if paid.len() > /* ~ changed by cargo-mutants ~ */ times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n }\n out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:66:23: replace < with > in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": ">",
|
|
"span": {
|
|
"end": {
|
|
"column": 24,
|
|
"line": 66
|
|
},
|
|
"start": {
|
|
"column": 23,
|
|
"line": 66
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace < with <= in sampled_equities\n@@ -58,17 +58,17 @@\n let mut rng = Rng::seeded(SAMPLE_SEED);\n for _ in 0..SAMPLES {\n times.clear();\n for (i, stack) in stacks.iter().enumerate() {\n let (u, next) = rng.unit();\n rng = next;\n times.push((-(1.0 - u).ln() / stack, i));\n }\n- if paid.len() < times.len() {\n+ if paid.len() <= /* ~ changed by cargo-mutants ~ */ times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n }\n out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:66:23: replace < with <= in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "<=",
|
|
"span": {
|
|
"end": {
|
|
"column": 24,
|
|
"line": 66
|
|
},
|
|
"start": {
|
|
"column": 23,
|
|
"line": 66
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace += with -= in sampled_equities\n@@ -63,13 +63,13 @@\n rng = next;\n times.push((-(1.0 - u).ln() / stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n- out[*player] += prize;\n+ out[*player] -= /* ~ changed by cargo-mutants ~ */ prize;\n }\n }\n out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:71:26: replace += with -= in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "-=",
|
|
"span": {
|
|
"end": {
|
|
"column": 28,
|
|
"line": 71
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 71
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace += with *= in sampled_equities\n@@ -63,13 +63,13 @@\n rng = next;\n times.push((-(1.0 - u).ln() / stack, i));\n }\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n- out[*player] += prize;\n+ out[*player] *= /* ~ changed by cargo-mutants ~ */ prize;\n }\n }\n out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:71:26: replace += with *= in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "*=",
|
|
"span": {
|
|
"end": {
|
|
"column": 28,
|
|
"line": 71
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 71
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace / with % in sampled_equities\n@@ -66,10 +66,10 @@\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n }\n- out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n+ out.iter().map(|x| x % /* ~ changed by cargo-mutants ~ */ f64::from(SAMPLES)).collect()\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:74:26: replace / with % in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "%",
|
|
"span": {
|
|
"end": {
|
|
"column": 27,
|
|
"line": 74
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 74
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/harville.rs\n+++ replace / with * in sampled_equities\n@@ -66,10 +66,10 @@\n if paid.len() < times.len() {\n times.select_nth_unstable_by(paid.len(), by_time);\n }\n times[..paid.len()].sort_unstable_by(by_time);\n for ((_, player), prize) in times.iter().zip(paid) {\n out[*player] += prize;\n }\n }\n- out.iter().map(|x| x / f64::from(SAMPLES)).collect()\n+ out.iter().map(|x| x * /* ~ changed by cargo-mutants ~ */ f64::from(SAMPLES)).collect()\n }\n",
|
|
"file": "src/icm/harville.rs",
|
|
"function": {
|
|
"function_name": "sampled_equities",
|
|
"return_type": "-> Vec<f64>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 75
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 50
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/harville.rs:74:26: replace / with * in sampled_equities",
|
|
"package": "pokerfreak",
|
|
"replacement": "*",
|
|
"span": {
|
|
"end": {
|
|
"column": 27,
|
|
"line": 74
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 74
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace Turnierlage::players -> usize with 0\n@@ -11,17 +11,17 @@\n pub ante: f64,\n /// Blind level (informational).\n pub level: u32,\n }\n \n impl Turnierlage {\n /// Players in the field who still have chips.\n pub fn players(&self) -> usize {\n- self.stacks.len()\n+ 0 /* ~ changed by cargo-mutants ~ */\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::players",
|
|
"return_type": "-> usize",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 20
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 17
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/lage.rs:19:9: replace Turnierlage::players -> usize with 0",
|
|
"package": "pokerfreak",
|
|
"replacement": "0",
|
|
"span": {
|
|
"end": {
|
|
"column": 26,
|
|
"line": 19
|
|
},
|
|
"start": {
|
|
"column": 9,
|
|
"line": 19
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace Turnierlage::players -> usize with 1\n@@ -11,17 +11,17 @@\n pub ante: f64,\n /// Blind level (informational).\n pub level: u32,\n }\n \n impl Turnierlage {\n /// Players in the field who still have chips.\n pub fn players(&self) -> usize {\n- self.stacks.len()\n+ 1 /* ~ changed by cargo-mutants ~ */\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::players",
|
|
"return_type": "-> usize",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 20
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 17
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/lage.rs:19:9: replace Turnierlage::players -> usize with 1",
|
|
"package": "pokerfreak",
|
|
"replacement": "1",
|
|
"span": {
|
|
"end": {
|
|
"column": 26,
|
|
"line": 19
|
|
},
|
|
"start": {
|
|
"column": 9,
|
|
"line": 19
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace Turnierlage::is_usable -> bool with true\n@@ -17,16 +17,11 @@\n /// Players in the field who still have chips.\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n- !self.payouts.is_empty()\n- && self.hero < self.stacks.len()\n- && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n- && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n- && self.payouts.iter().sum::<f64>() > 0.0\n+ true /* ~ changed by cargo-mutants ~ */\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/lage.rs:25:9: replace Turnierlage::is_usable -> bool with true",
|
|
"package": "pokerfreak",
|
|
"replacement": "true",
|
|
"span": {
|
|
"end": {
|
|
"column": 54,
|
|
"line": 30
|
|
},
|
|
"start": {
|
|
"column": 9,
|
|
"line": 25
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace Turnierlage::is_usable -> bool with false\n@@ -17,16 +17,11 @@\n /// Players in the field who still have chips.\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n- !self.payouts.is_empty()\n- && self.hero < self.stacks.len()\n- && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n- && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n- && self.payouts.iter().sum::<f64>() > 0.0\n+ false /* ~ changed by cargo-mutants ~ */\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/icm/lage.rs:25:9: replace Turnierlage::is_usable -> bool with false",
|
|
"package": "pokerfreak",
|
|
"replacement": "false",
|
|
"span": {
|
|
"end": {
|
|
"column": 54,
|
|
"line": 30
|
|
},
|
|
"start": {
|
|
"column": 9,
|
|
"line": 25
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -22,11 +22,11 @@\n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n- && self.payouts.iter().sum::<f64>() > 0.0\n+ || /* ~ changed by cargo-mutants ~ */ self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:30:13: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 15,
|
|
"line": 30
|
|
},
|
|
"start": {
|
|
"column": 13,
|
|
"line": 30
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -21,12 +21,12 @@\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n- && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n+ || /* ~ changed by cargo-mutants ~ */ self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:29:13: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 15,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 13,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -20,13 +20,13 @@\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n+ || /* ~ changed by cargo-mutants ~ */ self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:28:13: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 15,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 13,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -19,14 +19,14 @@\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n- && self.stacks.len() <= super::harville::MAX_FIELD\n+ || /* ~ changed by cargo-mutants ~ */ self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:27:13: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 15,
|
|
"line": 27
|
|
},
|
|
"start": {
|
|
"column": 13,
|
|
"line": 27
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -18,15 +18,15 @@\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n- && self.hero < self.stacks.len()\n+ || /* ~ changed by cargo-mutants ~ */ self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:26:13: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 15,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 13,
|
|
"line": 26
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ delete ! in Turnierlage::is_usable\n@@ -17,16 +17,16 @@\n /// Players in the field who still have chips.\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n- !self.payouts.is_empty()\n+ /* ~ changed by cargo-mutants ~ */self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "UnaryOperator",
|
|
"name": "src/icm/lage.rs:25:9: delete ! in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "",
|
|
"span": {
|
|
"end": {
|
|
"column": 10,
|
|
"line": 25
|
|
},
|
|
"start": {
|
|
"column": 9,
|
|
"line": 25
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace < with == in Turnierlage::is_usable\n@@ -18,15 +18,15 @@\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n- && self.hero < self.stacks.len()\n+ && self.hero == /* ~ changed by cargo-mutants ~ */ self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:26:26: replace < with == in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "==",
|
|
"span": {
|
|
"end": {
|
|
"column": 27,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 26
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace < with > in Turnierlage::is_usable\n@@ -18,15 +18,15 @@\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n- && self.hero < self.stacks.len()\n+ && self.hero > /* ~ changed by cargo-mutants ~ */ self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:26:26: replace < with > in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": ">",
|
|
"span": {
|
|
"end": {
|
|
"column": 27,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 26
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace < with <= in Turnierlage::is_usable\n@@ -18,15 +18,15 @@\n pub fn players(&self) -> usize {\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n- && self.hero < self.stacks.len()\n+ && self.hero <= /* ~ changed by cargo-mutants ~ */ self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:26:26: replace < with <= in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "<=",
|
|
"span": {
|
|
"end": {
|
|
"column": 27,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 26,
|
|
"line": 26
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace <= with > in Turnierlage::is_usable\n@@ -19,14 +19,14 @@\n self.stacks.len()\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n- && self.stacks.len() <= super::harville::MAX_FIELD\n+ && self.stacks.len() > /* ~ changed by cargo-mutants ~ */ super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:27:34: replace <= with > in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": ">",
|
|
"span": {
|
|
"end": {
|
|
"column": 36,
|
|
"line": 27
|
|
},
|
|
"start": {
|
|
"column": 34,
|
|
"line": 27
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -20,13 +20,13 @@\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n+ && self.stacks.iter().all(|s| s.is_finite() || /* ~ changed by cargo-mutants ~ */ *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:28:57: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 59,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 57,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace > with == in Turnierlage::is_usable\n@@ -20,13 +20,13 @@\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n+ && self.stacks.iter().all(|s| s.is_finite() && *s == /* ~ changed by cargo-mutants ~ */ 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:28:63: replace > with == in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "==",
|
|
"span": {
|
|
"end": {
|
|
"column": 64,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 63,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace > with < in Turnierlage::is_usable\n@@ -20,13 +20,13 @@\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n+ && self.stacks.iter().all(|s| s.is_finite() && *s < /* ~ changed by cargo-mutants ~ */ 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:28:63: replace > with < in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "<",
|
|
"span": {
|
|
"end": {
|
|
"column": 64,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 63,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace > with >= in Turnierlage::is_usable\n@@ -20,13 +20,13 @@\n }\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n- && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n+ && self.stacks.iter().all(|s| s.is_finite() && *s >= /* ~ changed by cargo-mutants ~ */ 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:28:63: replace > with >= in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": ">=",
|
|
"span": {
|
|
"end": {
|
|
"column": 64,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 63,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace && with || in Turnierlage::is_usable\n@@ -21,12 +21,12 @@\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n- && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n+ && self.payouts.iter().all(|p| p.is_finite() || /* ~ changed by cargo-mutants ~ */ *p >= 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:29:58: replace && with || in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "||",
|
|
"span": {
|
|
"end": {
|
|
"column": 60,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 58,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace >= with < in Turnierlage::is_usable\n@@ -21,12 +21,12 @@\n \n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n- && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n+ && self.payouts.iter().all(|p| p.is_finite() && *p < /* ~ changed by cargo-mutants ~ */ 0.0)\n && self.payouts.iter().sum::<f64>() > 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:29:64: replace >= with < in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "<",
|
|
"span": {
|
|
"end": {
|
|
"column": 66,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 64,
|
|
"line": 29
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace > with == in Turnierlage::is_usable\n@@ -22,11 +22,11 @@\n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n- && self.payouts.iter().sum::<f64>() > 0.0\n+ && self.payouts.iter().sum::<f64>() == /* ~ changed by cargo-mutants ~ */ 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:30:49: replace > with == in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "==",
|
|
"span": {
|
|
"end": {
|
|
"column": 50,
|
|
"line": 30
|
|
},
|
|
"start": {
|
|
"column": 49,
|
|
"line": 30
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace > with < in Turnierlage::is_usable\n@@ -22,11 +22,11 @@\n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n- && self.payouts.iter().sum::<f64>() > 0.0\n+ && self.payouts.iter().sum::<f64>() < /* ~ changed by cargo-mutants ~ */ 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:30:49: replace > with < in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": "<",
|
|
"span": {
|
|
"end": {
|
|
"column": 50,
|
|
"line": 30
|
|
},
|
|
"start": {
|
|
"column": 49,
|
|
"line": 30
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/icm/lage.rs\n+++ replace > with >= in Turnierlage::is_usable\n@@ -22,11 +22,11 @@\n /// Every number finite, stacks positive, payouts non-negative with a positive sum, hero\n /// inside the field, field no larger than `harville::MAX_FIELD`.\n pub fn is_usable(&self) -> bool {\n !self.payouts.is_empty()\n && self.hero < self.stacks.len()\n && self.stacks.len() <= super::harville::MAX_FIELD\n && self.stacks.iter().all(|s| s.is_finite() && *s > 0.0)\n && self.payouts.iter().all(|p| p.is_finite() && *p >= 0.0)\n- && self.payouts.iter().sum::<f64>() > 0.0\n+ && self.payouts.iter().sum::<f64>() >= /* ~ changed by cargo-mutants ~ */ 0.0\n }\n }\n",
|
|
"file": "src/icm/lage.rs",
|
|
"function": {
|
|
"function_name": "Turnierlage::is_usable",
|
|
"return_type": "-> bool",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 31
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "BinaryOperator",
|
|
"name": "src/icm/lage.rs:30:49: replace > with >= in Turnierlage::is_usable",
|
|
"package": "pokerfreak",
|
|
"replacement": ">=",
|
|
"span": {
|
|
"end": {
|
|
"column": 50,
|
|
"line": 30
|
|
},
|
|
"start": {
|
|
"column": 49,
|
|
"line": 30
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_extras.rs\n+++ replace extras -> Result<Extras, Fault> with Ok(Default::default())\n@@ -16,14 +16,10 @@\n /// `ritOffered`: the table offers to run it twice; absent or `null` means no.\n pub rit_offered: bool,\n /// `tournament`: the situation to price the decision in money; absent means cash.\n pub tournament: Option<Turnierlage>,\n }\n \n /// Read after the `Spot` checks, so faults of contract fields keep their precedence.\n pub fn extras(root: &Value) -> Result<Extras, Fault> {\n- let rit_offered = match optional(root, \"\", \"ritOffered\")? {\n- Some(value) => flag(value, \"ritOffered\")?,\n- None => false,\n- };\n- Ok(Extras { board_double: board_double(root)?, rit_offered, tournament: tournament(root)? })\n+ Ok(Default::default()) /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/wire/decode_extras.rs",
|
|
"function": {
|
|
"function_name": "extras",
|
|
"return_type": "-> Result<Extras, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 29
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 22
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_extras.rs:24:5: replace extras -> Result<Extras, Fault> with Ok(Default::default())",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(Default::default())",
|
|
"span": {
|
|
"end": {
|
|
"column": 97,
|
|
"line": 28
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 24
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![])\n@@ -3,18 +3,17 @@\n use crate::json::field::{at, join, optional, required};\n use crate::json::member::{items_member, opt_number_member, opt_u64_member};\n use crate::json::scalar::{number, whole_u64};\n use crate::json::Value;\n \n const PATH: &str = \"tournament\";\n \n fn numbers(object: &Value, key: &str) -> Result<Vec<f64>, Fault> {\n- let path = join(PATH, key);\n- items_member(object, PATH, key)?.iter().enumerate().map(|(i, v)| number(v, &at(&path, i))).collect()\n+ Ok(vec![]) /* ~ changed by cargo-mutants ~ */\n }\n \n fn whole<T: TryFrom<u64>>(n: u64, key: &str) -> Result<T, Fault> {\n T::try_from(n).map_err(|_| Fault::Invalid { field: join(PATH, key), detail: format!(\"{n} is out of range\") })\n }\n \n /// Extension field `tournament`: the tournament situation the answer is priced in (ICM-lite).\n ///\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "numbers",
|
|
"return_type": "-> Result<Vec<f64>, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 13
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 10
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:11:5: replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![])",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(vec![])",
|
|
"span": {
|
|
"end": {
|
|
"column": 105,
|
|
"line": 12
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 11
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![0.0])\n@@ -3,18 +3,17 @@\n use crate::json::field::{at, join, optional, required};\n use crate::json::member::{items_member, opt_number_member, opt_u64_member};\n use crate::json::scalar::{number, whole_u64};\n use crate::json::Value;\n \n const PATH: &str = \"tournament\";\n \n fn numbers(object: &Value, key: &str) -> Result<Vec<f64>, Fault> {\n- let path = join(PATH, key);\n- items_member(object, PATH, key)?.iter().enumerate().map(|(i, v)| number(v, &at(&path, i))).collect()\n+ Ok(vec![0.0]) /* ~ changed by cargo-mutants ~ */\n }\n \n fn whole<T: TryFrom<u64>>(n: u64, key: &str) -> Result<T, Fault> {\n T::try_from(n).map_err(|_| Fault::Invalid { field: join(PATH, key), detail: format!(\"{n} is out of range\") })\n }\n \n /// Extension field `tournament`: the tournament situation the answer is priced in (ICM-lite).\n ///\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "numbers",
|
|
"return_type": "-> Result<Vec<f64>, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 13
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 10
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:11:5: replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![0.0])",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(vec![0.0])",
|
|
"span": {
|
|
"end": {
|
|
"column": 105,
|
|
"line": 12
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 11
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![1.0])\n@@ -3,18 +3,17 @@\n use crate::json::field::{at, join, optional, required};\n use crate::json::member::{items_member, opt_number_member, opt_u64_member};\n use crate::json::scalar::{number, whole_u64};\n use crate::json::Value;\n \n const PATH: &str = \"tournament\";\n \n fn numbers(object: &Value, key: &str) -> Result<Vec<f64>, Fault> {\n- let path = join(PATH, key);\n- items_member(object, PATH, key)?.iter().enumerate().map(|(i, v)| number(v, &at(&path, i))).collect()\n+ Ok(vec![1.0]) /* ~ changed by cargo-mutants ~ */\n }\n \n fn whole<T: TryFrom<u64>>(n: u64, key: &str) -> Result<T, Fault> {\n T::try_from(n).map_err(|_| Fault::Invalid { field: join(PATH, key), detail: format!(\"{n} is out of range\") })\n }\n \n /// Extension field `tournament`: the tournament situation the answer is priced in (ICM-lite).\n ///\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "numbers",
|
|
"return_type": "-> Result<Vec<f64>, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 13
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 10
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:11:5: replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![1.0])",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(vec![1.0])",
|
|
"span": {
|
|
"end": {
|
|
"column": 105,
|
|
"line": 12
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 11
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![-1.0])\n@@ -3,18 +3,17 @@\n use crate::json::field::{at, join, optional, required};\n use crate::json::member::{items_member, opt_number_member, opt_u64_member};\n use crate::json::scalar::{number, whole_u64};\n use crate::json::Value;\n \n const PATH: &str = \"tournament\";\n \n fn numbers(object: &Value, key: &str) -> Result<Vec<f64>, Fault> {\n- let path = join(PATH, key);\n- items_member(object, PATH, key)?.iter().enumerate().map(|(i, v)| number(v, &at(&path, i))).collect()\n+ Ok(vec![-1.0]) /* ~ changed by cargo-mutants ~ */\n }\n \n fn whole<T: TryFrom<u64>>(n: u64, key: &str) -> Result<T, Fault> {\n T::try_from(n).map_err(|_| Fault::Invalid { field: join(PATH, key), detail: format!(\"{n} is out of range\") })\n }\n \n /// Extension field `tournament`: the tournament situation the answer is priced in (ICM-lite).\n ///\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "numbers",
|
|
"return_type": "-> Result<Vec<f64>, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 13
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 10
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:11:5: replace numbers -> Result<Vec<f64>, Fault> with Ok(vec![-1.0])",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(vec![-1.0])",
|
|
"span": {
|
|
"end": {
|
|
"column": 105,
|
|
"line": 12
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 11
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace whole -> Result<T, Fault> with Ok(Default::default())\n@@ -8,17 +8,17 @@\n const PATH: &str = \"tournament\";\n \n fn numbers(object: &Value, key: &str) -> Result<Vec<f64>, Fault> {\n let path = join(PATH, key);\n items_member(object, PATH, key)?.iter().enumerate().map(|(i, v)| number(v, &at(&path, i))).collect()\n }\n \n fn whole<T: TryFrom<u64>>(n: u64, key: &str) -> Result<T, Fault> {\n- T::try_from(n).map_err(|_| Fault::Invalid { field: join(PATH, key), detail: format!(\"{n} is out of range\") })\n+ Ok(Default::default()) /* ~ changed by cargo-mutants ~ */\n }\n \n /// Extension field `tournament`: the tournament situation the answer is priced in (ICM-lite).\n ///\n /// ```text\n /// \"tournament\": {\"payouts\": [27.76, 18.27, ...], \"stacks\": [8000, 12500, ...],\n /// \"heroIndex\": 0, \"ante\": 250, \"level\": 18}\n /// ```\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "whole",
|
|
"return_type": "-> Result<T, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 17
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 15
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:16:5: replace whole -> Result<T, Fault> with Ok(Default::default())",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(Default::default())",
|
|
"span": {
|
|
"end": {
|
|
"column": 114,
|
|
"line": 16
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 16
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace tournament -> Result<Option<Turnierlage>, Fault> with Ok(None)\n@@ -28,20 +28,10 @@\n /// in the unit of the request's amounts.\n /// - `heroIndex`: hero's index in `stacks`.\n /// - `ante`, `level` (optional, default 0): informational.\n ///\n /// Absent or `null` means cash. Wrong types are a `Fault`; values that are well-formed but\n /// cannot be priced (no payouts, hero outside the field, a stack of 0) make the engine\n /// abstain (`Turnierlage::is_usable`).\n pub fn tournament(root: &Value) -> Result<Option<Turnierlage>, Fault> {\n- let Some(object) = optional(root, \"\", PATH)? else {\n- return Ok(None);\n- };\n- let hero = whole_u64(required(object, PATH, \"heroIndex\")?, &join(PATH, \"heroIndex\"))?;\n- Ok(Some(Turnierlage {\n- payouts: numbers(object, \"payouts\")?,\n- stacks: numbers(object, \"stacks\")?,\n- hero: whole(hero, \"heroIndex\")?,\n- ante: opt_number_member(object, PATH, \"ante\")?.unwrap_or(0.0),\n- level: opt_u64_member(object, PATH, \"level\")?.map(|n| whole(n, \"level\")).transpose()?.unwrap_or(0),\n- }))\n+ Ok(None) /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "tournament",
|
|
"return_type": "-> Result<Option<Turnierlage>, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 19
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:36:5: replace tournament -> Result<Option<Turnierlage>, Fault> with Ok(None)",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(None)",
|
|
"span": {
|
|
"end": {
|
|
"column": 8,
|
|
"line": 46
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/decode_tournament.rs\n+++ replace tournament -> Result<Option<Turnierlage>, Fault> with Ok(Some(Default::default()))\n@@ -28,20 +28,10 @@\n /// in the unit of the request's amounts.\n /// - `heroIndex`: hero's index in `stacks`.\n /// - `ante`, `level` (optional, default 0): informational.\n ///\n /// Absent or `null` means cash. Wrong types are a `Fault`; values that are well-formed but\n /// cannot be priced (no payouts, hero outside the field, a stack of 0) make the engine\n /// abstain (`Turnierlage::is_usable`).\n pub fn tournament(root: &Value) -> Result<Option<Turnierlage>, Fault> {\n- let Some(object) = optional(root, \"\", PATH)? else {\n- return Ok(None);\n- };\n- let hero = whole_u64(required(object, PATH, \"heroIndex\")?, &join(PATH, \"heroIndex\"))?;\n- Ok(Some(Turnierlage {\n- payouts: numbers(object, \"payouts\")?,\n- stacks: numbers(object, \"stacks\")?,\n- hero: whole(hero, \"heroIndex\")?,\n- ante: opt_number_member(object, PATH, \"ante\")?.unwrap_or(0.0),\n- level: opt_u64_member(object, PATH, \"level\")?.map(|n| whole(n, \"level\")).transpose()?.unwrap_or(0),\n- }))\n+ Ok(Some(Default::default())) /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/wire/decode_tournament.rs",
|
|
"function": {
|
|
"function_name": "tournament",
|
|
"return_type": "-> Result<Option<Turnierlage>, Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 47
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 19
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/decode_tournament.rs:36:5: replace tournament -> Result<Option<Turnierlage>, Fault> with Ok(Some(Default::default()))",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok(Some(Default::default()))",
|
|
"span": {
|
|
"end": {
|
|
"column": 8,
|
|
"line": 46
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 36
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/respond.rs\n+++ replace pipeline -> Result<(Decision, Option<(RunTwice, String)>), Fault> with Ok((Default::default(), None))\n@@ -6,28 +6,17 @@\n use crate::engine::run_twice::{run_twice, RunTwice};\n use crate::fault::Fault;\n use crate::game::{Decision, Spot};\n use crate::guard::enforce::enforce;\n use crate::guard::validate::check;\n use crate::json::{parse, render, Value};\n \n fn pipeline(line: &str) -> Result<(Decision, Option<(RunTwice, String)>), Fault> {\n- let value = parse(line)?;\n- let spot: Spot = check(decode(&value)?)?;\n- let extras = extras(&value)?;\n- let decision = match &extras.board_double {\n- Some(second) => decide_double(&spot, second),\n- None => match &extras.tournament {\n- Some(lage) => decide_with(&spot, Some(lage)),\n- None => enforce(&spot, decide(&spot)),\n- },\n- };\n- let rit = extras.rit_offered.then(|| run_twice(&spot, &decision));\n- Ok((decision, rit))\n+ Ok((Default::default(), None)) /* ~ changed by cargo-mutants ~ */\n }\n \n /// One request line in, one response line out (without trailing newline). Never panics.\n /// With `ritOffered` the answer carries `rit` and `ritReason` after the contract keys.\n pub fn respond(line: &str) -> String {\n match pipeline(line) {\n Ok((decision, None)) => encode(&decision),\n Ok((decision, Some((answer, reason)))) => {\n",
|
|
"file": "src/wire/respond.rs",
|
|
"function": {
|
|
"function_name": "pipeline",
|
|
"return_type": "-> Result<(Decision, Option<(RunTwice, String)>), Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 13
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/respond.rs:14:5: replace pipeline -> Result<(Decision, Option<(RunTwice, String)>), Fault> with Ok((Default::default(), None))",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok((Default::default(), None))",
|
|
"span": {
|
|
"end": {
|
|
"column": 24,
|
|
"line": 25
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 14
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/respond.rs\n+++ replace pipeline -> Result<(Decision, Option<(RunTwice, String)>), Fault> with Ok((Default::default(), Some((Default::default(), String::new()))))\n@@ -6,28 +6,17 @@\n use crate::engine::run_twice::{run_twice, RunTwice};\n use crate::fault::Fault;\n use crate::game::{Decision, Spot};\n use crate::guard::enforce::enforce;\n use crate::guard::validate::check;\n use crate::json::{parse, render, Value};\n \n fn pipeline(line: &str) -> Result<(Decision, Option<(RunTwice, String)>), Fault> {\n- let value = parse(line)?;\n- let spot: Spot = check(decode(&value)?)?;\n- let extras = extras(&value)?;\n- let decision = match &extras.board_double {\n- Some(second) => decide_double(&spot, second),\n- None => match &extras.tournament {\n- Some(lage) => decide_with(&spot, Some(lage)),\n- None => enforce(&spot, decide(&spot)),\n- },\n- };\n- let rit = extras.rit_offered.then(|| run_twice(&spot, &decision));\n- Ok((decision, rit))\n+ Ok((Default::default(), Some((Default::default(), String::new())))) /* ~ changed by cargo-mutants ~ */\n }\n \n /// One request line in, one response line out (without trailing newline). Never panics.\n /// With `ritOffered` the answer carries `rit` and `ritReason` after the contract keys.\n pub fn respond(line: &str) -> String {\n match pipeline(line) {\n Ok((decision, None)) => encode(&decision),\n Ok((decision, Some((answer, reason)))) => {\n",
|
|
"file": "src/wire/respond.rs",
|
|
"function": {
|
|
"function_name": "pipeline",
|
|
"return_type": "-> Result<(Decision, Option<(RunTwice, String)>), Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 13
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/respond.rs:14:5: replace pipeline -> Result<(Decision, Option<(RunTwice, String)>), Fault> with Ok((Default::default(), Some((Default::default(), String::new()))))",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok((Default::default(), Some((Default::default(), String::new()))))",
|
|
"span": {
|
|
"end": {
|
|
"column": 24,
|
|
"line": 25
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 14
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/respond.rs\n+++ replace pipeline -> Result<(Decision, Option<(RunTwice, String)>), Fault> with Ok((Default::default(), Some((Default::default(), \"xyzzy\".into()))))\n@@ -6,28 +6,17 @@\n use crate::engine::run_twice::{run_twice, RunTwice};\n use crate::fault::Fault;\n use crate::game::{Decision, Spot};\n use crate::guard::enforce::enforce;\n use crate::guard::validate::check;\n use crate::json::{parse, render, Value};\n \n fn pipeline(line: &str) -> Result<(Decision, Option<(RunTwice, String)>), Fault> {\n- let value = parse(line)?;\n- let spot: Spot = check(decode(&value)?)?;\n- let extras = extras(&value)?;\n- let decision = match &extras.board_double {\n- Some(second) => decide_double(&spot, second),\n- None => match &extras.tournament {\n- Some(lage) => decide_with(&spot, Some(lage)),\n- None => enforce(&spot, decide(&spot)),\n- },\n- };\n- let rit = extras.rit_offered.then(|| run_twice(&spot, &decision));\n- Ok((decision, rit))\n+ Ok((Default::default(), Some((Default::default(), \"xyzzy\".into())))) /* ~ changed by cargo-mutants ~ */\n }\n \n /// One request line in, one response line out (without trailing newline). Never panics.\n /// With `ritOffered` the answer carries `rit` and `ritReason` after the contract keys.\n pub fn respond(line: &str) -> String {\n match pipeline(line) {\n Ok((decision, None)) => encode(&decision),\n Ok((decision, Some((answer, reason)))) => {\n",
|
|
"file": "src/wire/respond.rs",
|
|
"function": {
|
|
"function_name": "pipeline",
|
|
"return_type": "-> Result<(Decision, Option<(RunTwice, String)>), Fault>",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 26
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 13
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/respond.rs:14:5: replace pipeline -> Result<(Decision, Option<(RunTwice, String)>), Fault> with Ok((Default::default(), Some((Default::default(), \"xyzzy\".into()))))",
|
|
"package": "pokerfreak",
|
|
"replacement": "Ok((Default::default(), Some((Default::default(), \"xyzzy\".into()))))",
|
|
"span": {
|
|
"end": {
|
|
"column": 24,
|
|
"line": 25
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 14
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/respond.rs\n+++ replace respond -> String with String::new()\n@@ -23,21 +23,10 @@\n };\n let rit = extras.rit_offered.then(|| run_twice(&spot, &decision));\n Ok((decision, rit))\n }\n \n /// One request line in, one response line out (without trailing newline). Never panics.\n /// With `ritOffered` the answer carries `rit` and `ritReason` after the contract keys.\n pub fn respond(line: &str) -> String {\n- match pipeline(line) {\n- Ok((decision, None)) => encode(&decision),\n- Ok((decision, Some((answer, reason)))) => {\n- let Value::Object(mut felder) = encode_value(&decision) else {\n- return encode(&decision);\n- };\n- felder.push((\"rit\".to_string(), Value::String(answer.name().to_string())));\n- felder.push((\"ritReason\".to_string(), Value::String(reason)));\n- render(&Value::Object(felder))\n- }\n- Err(fault) => encode(&Decision::abstain(format!(\"invalid request: {fault}\"))),\n- }\n+ String::new() /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/wire/respond.rs",
|
|
"function": {
|
|
"function_name": "respond",
|
|
"return_type": "-> String",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 43
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/respond.rs:31:5: replace respond -> String with String::new()",
|
|
"package": "pokerfreak",
|
|
"replacement": "String::new()",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 42
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 31
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"diff": "--- src/wire/respond.rs\n+++ replace respond -> String with \"xyzzy\".into()\n@@ -23,21 +23,10 @@\n };\n let rit = extras.rit_offered.then(|| run_twice(&spot, &decision));\n Ok((decision, rit))\n }\n \n /// One request line in, one response line out (without trailing newline). Never panics.\n /// With `ritOffered` the answer carries `rit` and `ritReason` after the contract keys.\n pub fn respond(line: &str) -> String {\n- match pipeline(line) {\n- Ok((decision, None)) => encode(&decision),\n- Ok((decision, Some((answer, reason)))) => {\n- let Value::Object(mut felder) = encode_value(&decision) else {\n- return encode(&decision);\n- };\n- felder.push((\"rit\".to_string(), Value::String(answer.name().to_string())));\n- felder.push((\"ritReason\".to_string(), Value::String(reason)));\n- render(&Value::Object(felder))\n- }\n- Err(fault) => encode(&Decision::abstain(format!(\"invalid request: {fault}\"))),\n- }\n+ \"xyzzy\".into() /* ~ changed by cargo-mutants ~ */\n }\n",
|
|
"file": "src/wire/respond.rs",
|
|
"function": {
|
|
"function_name": "respond",
|
|
"return_type": "-> String",
|
|
"span": {
|
|
"end": {
|
|
"column": 2,
|
|
"line": 43
|
|
},
|
|
"start": {
|
|
"column": 1,
|
|
"line": 28
|
|
}
|
|
}
|
|
},
|
|
"genre": "FnValue",
|
|
"name": "src/wire/respond.rs:31:5: replace respond -> String with \"xyzzy\".into()",
|
|
"package": "pokerfreak",
|
|
"replacement": "\"xyzzy\".into()",
|
|
"span": {
|
|
"end": {
|
|
"column": 6,
|
|
"line": 42
|
|
},
|
|
"start": {
|
|
"column": 5,
|
|
"line": 31
|
|
}
|
|
}
|
|
}
|
|
] |