}
}
-impl<'c> ResolveContext<'c> {
+impl Aggregate {
fn lookup_raw<'n, S>(&self, key: &'static str, sections: S)
- -> Option<&'c RawVal>
+ -> Option<&RawVal>
where S: Iterator<Item=&'n SectionName>
{
for section in sections {
- if let Some(raw) = self.agg.sections
+ if let Some(raw) = self.sections
.get(section)
.and_then(|vars: &SectionMap| vars.get(key))
{
}
None
}
+}
+impl<'c> ResolveContext<'c> {
fn first_of_raw(&self, key: &'static str, sections: SectionKindList)
-> Option<&'c RawVal> {
- self.lookup_raw(
+ self.agg.lookup_raw(
key,
self.all_sections.iter()
.filter(|s| sections.contains(s))
#[throws(AE)]
pub fn special_server(&self, key: &'static str) -> ServerName {
- let raw = match self.lookup_raw(
+ let raw = match self.agg.lookup_raw(
"server",
[ &SectionName::Common, &self.special_server_section ].iter().cloned()
) {