From 65aca9cbf0318bd3a2f936641b4f5bc3729c98c2 Mon Sep 17 00:00:00 2001 From: Martin Fischer Date: Wed, 16 Aug 2023 09:45:18 +0200 Subject: break!: introduce AttributeMap This has a number of benefits: * it hides the implementation of the map * it hides the type used for the map values (which lets us e.g. change name_span to name_offset while still being able to provide a convenient `Attribute::name_span` method.) * it lets us provide convenience impls for the map such as `FromIterator<(String, String)>` --- integration_tests/tests/test_html5lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'integration_tests') diff --git a/integration_tests/tests/test_html5lib.rs b/integration_tests/tests/test_html5lib.rs index 0f96063..a624c30 100644 --- a/integration_tests/tests/test_html5lib.rs +++ b/integration_tests/tests/test_html5lib.rs @@ -129,7 +129,7 @@ fn run_test_inner( attributes: tag .attributes .into_iter() - .map(|(name, map_val)| (name, map_val.value)) + .map(|attr| (attr.name().to_owned(), attr.value().to_owned())) .collect(), self_closing: tag.self_closing, }), -- cgit v1.2.3