MCPcopy Create free account
hub / github.com/SeaQL/FireDBG.for.Rust / union_v

Method union_v

debugger/src/reader.rs:214–229  ·  view source on GitHub ↗
(
        &mut self,
        t: &UnionType,
        index: usize,
        fields: I,
    )

Source from the content-addressed store, hash-verified

212 }
213
214 fn union_v<I: Iterator<Item = (String, RValue)>>(
215 &mut self,
216 t: &UnionType,
217 index: usize,
218 fields: I,
219 ) -> RValue {
220 let mut f = IndexMap::new();
221 fields.for_each(|p| {
222 f.insert(p.0, p.1);
223 });
224 RValue::Union {
225 typeinfo: t.clone(),
226 variant: t.variants[index].clone(),
227 fields: f,
228 }
229 }
230
231 fn vector_v<I: Iterator<Item = RValue>>(&self, iter: I) -> RValue {
232 RValue::Array {

Callers 3

write_resultMethod · 0.45
write_optionMethod · 0.45
read_valuesMethod · 0.45

Calls 1

insertMethod · 0.80

Tested by

no test coverage detected