File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change 1
1
import { BLACK } from '../color/BLACK.js' ;
2
2
3
3
/**
4
- * Recursively constructs a prettyprint string for the red-black tree rooted at
5
- * <code>root</code>.
4
+ * Builds a debug function from color handlers.
6
5
*
7
- * @param {Node } root - The root of the tree .
8
- * @returns {String }
6
+ * @param {Object } colors The colors to use .
7
+ * @returns {Function } The debug function.
9
8
*/
10
- export function _debug ( { red, black} ) {
9
+ export const _debug = ( { red, black} ) => {
10
+ /**
11
+ * Recursively constructs a prettyprint string for the red-black tree rooted at
12
+ * <code>root</code>.
13
+ *
14
+ * @param {Node } root - The root of the tree.
15
+ * @returns {string }
16
+ */
11
17
const debug = ( root ) => {
12
18
if ( root . isLeaf ( ) ) return black ( 'L' ) ;
13
19
@@ -17,4 +23,4 @@ export function _debug({red, black}) {
17
23
} ;
18
24
19
25
return debug ;
20
- }
26
+ } ;
You can’t perform that action at this time.
0 commit comments