(package: &Package)
| 389 | } |
| 390 | |
| 391 | pub fn get_element(package: &Package) -> Element { |
| 392 | let doc = package.as_document(); |
| 393 | let mut result = None; |
| 394 | for root_child in doc.root().children() { |
| 395 | if let ChildOfRoot::Element(e) = root_child { |
| 396 | assert!(result.is_none()); |
| 397 | result = Some(e); |
| 398 | } |
| 399 | }; |
| 400 | return result.unwrap(); |
| 401 | } |
| 402 | |
| 403 | #[allow(dead_code)] |
| 404 | fn trim_doc(doc: &Document) { |
no outgoing calls