Function g_spread
pub fn g_spread<C: YieldCurve<f64>>(
bond: &FixedRateBond,
government: &C,
dirty: f64,
settlement: NaiveDate,
basis: YieldBasis,
) -> Result<f64, SpreadSolveError>Expand description
G-spread: the bond’s yield over the government curve’s zero rate at its maturity.
spread_over_curve read against a sovereign benchmark. The verb exists so
a caller states which market the spread is against; the arithmetic is shared
with i_spread.