减少文本因子读取临时分配

This commit is contained in:
Boris
2026-08-26 05:08:34 +08:00
parent 77622e164c
commit 0867655d85
2 changed files with 11 additions and 4 deletions
+7
View File
@@ -2449,6 +2449,13 @@ impl DataSet {
.unwrap_or_default()
}
pub fn factor_text_rows_on(&self, date: NaiveDate) -> &[FactorTextValue] {
self.factor_text_by_date
.get(&date)
.map(Vec::as_slice)
.unwrap_or(&[])
}
pub fn market_snapshots_on(&self, date: NaiveDate) -> Vec<&DailyMarketSnapshot> {
self.market_by_date
.get(&date)