File tree Expand file tree Collapse file tree 3 files changed +7
-16
lines changed Expand file tree Collapse file tree 3 files changed +7
-16
lines changed Original file line number Diff line number Diff line change 1
1
---
2
- refs/heads/master: 2cdb662022a7427f9eff569fc211b1aed6f632ec
2
+ refs/heads/master: 0b2ffa854fd243055e3e41c7a6cd5116531afc9a
3
3
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4
4
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5
5
refs/heads/try: 2898dcc5d97da9427ac367542382b6239d9c0bbf
Original file line number Diff line number Diff line change @@ -6,19 +6,9 @@ import markdown_writer::writer_util;
6
6
export mk_pass;
7
7
export header_kind, header_name, header_text;
8
8
9
- fn mk_pass ( config : config:: config ) -> pass {
10
- mk_pass_ ( config, markdown_writer:: make_writer ( config) )
11
- }
12
-
13
- // FIXME: This is a really convoluted interface to work around trying
14
- // to get a writer into a unique closure and then being able to test
15
- // what was written afterward
16
- fn mk_pass_ (
17
- config : config:: config ,
18
- writer : writer
19
- ) -> pass {
9
+ fn mk_pass ( writer : writer ) -> pass {
20
10
let f = fn ~( srv: astsrv:: srv, doc: doc:: doc) -> doc:: doc {
21
- run( srv, doc, config , writer)
11
+ run( srv, doc, writer)
22
12
} ;
23
13
24
14
{
@@ -30,7 +20,6 @@ fn mk_pass_(
30
20
fn run (
31
21
srv : astsrv:: srv ,
32
22
doc : doc:: doc ,
33
- _config : config:: config ,
34
23
writer : writer
35
24
) -> doc:: doc {
36
25
@@ -969,7 +958,7 @@ mod test {
969
958
with config:: default_config ( "" )
970
959
} ;
971
960
let ( writer, future) = markdown_writer:: future_writer ( ) ;
972
- let pass = mk_pass_ ( config , writer) ;
961
+ let pass = mk_pass ( writer) ;
973
962
pass. f ( srv, doc) ;
974
963
ret future:: get ( future) ;
975
964
}
Original file line number Diff line number Diff line change @@ -156,7 +156,9 @@ fn run(config: config::config) {
156
156
sort_item_name_pass:: mk_pass ( ) ,
157
157
sort_item_type_pass:: mk_pass ( ) ,
158
158
markdown_index_pass:: mk_pass ( ) ,
159
- markdown_pass:: mk_pass ( config)
159
+ markdown_pass:: mk_pass (
160
+ markdown_writer:: make_writer ( config)
161
+ )
160
162
] ) ;
161
163
}
162
164
}
You can’t perform that action at this time.
0 commit comments