Skip to content

Commit d9c1a17

Browse files
QuietMisdreavusManishearth
authored andcommitted
give render_text a generic return type
1 parent 5db40f7 commit d9c1a17

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/librustdoc/html/render.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ thread_local!(pub static CURRENT_LOCATION_KEY: RefCell<Vec<String>> =
421421
thread_local!(pub static USED_ID_MAP: RefCell<FxHashMap<String, usize>> =
422422
RefCell::new(init_ids()));
423423

424-
pub fn render_text<F: FnMut(RenderType) -> String>(mut render: F) -> (String, String) {
424+
pub fn render_text<T, F: FnMut(RenderType) -> T>(mut render: F) -> (T, T) {
425425
// Save the state of USED_ID_MAP so it only gets updated once even
426426
// though we're rendering twice.
427427
let orig_used_id_map = USED_ID_MAP.with(|map| map.borrow().clone());

0 commit comments

Comments
 (0)