|
6 | 6 | declare global {
|
7 | 7 | /** Map from crate name to directory structure, for source view */
|
8 | 8 | declare var srcIndex: Map<string, rustdoc.Dir>;
|
9 |
| - /** Defined and documented in `main.js` */ |
| 9 | + /** Defined and documented in `storage.js` */ |
10 | 10 | declare function nonnull(x: T|null, msg: string|undefined);
|
| 11 | + /** Defined and documented in `storage.js` */ |
| 12 | + declare function nonundef(x: T|undefined, msg: string|undefined); |
11 | 13 | interface Window {
|
12 | 14 | /** Make the current theme easy to find */
|
13 | 15 | currentTheme: HTMLLinkElement|null;
|
@@ -255,12 +257,20 @@ declare namespace rustdoc {
|
255 | 257 | ty: number,
|
256 | 258 | type?: FunctionSearchType,
|
257 | 259 | paramNames?: string[],
|
258 |
| - displayType: Promise<Array<Array<string>>>|null, |
259 |
| - displayTypeMappedNames: Promise<Array<[string, Array<string>]>>|null, |
| 260 | + displayTypeSignature: Promise<rustdoc.DisplayTypeSignature> | null, |
260 | 261 | item: Row,
|
261 | 262 | dontValidate?: boolean,
|
262 | 263 | }
|
263 | 264 |
|
| 265 | + /** |
| 266 | + * output of `formatDisplayTypeSignature` |
| 267 | + */ |
| 268 | + interface DisplayTypeSignature { |
| 269 | + type: Array<string>, |
| 270 | + mappedNames: Map<string, string>, |
| 271 | + whereClause: Map<string, Array<string>>, |
| 272 | + } |
| 273 | + |
264 | 274 | /**
|
265 | 275 | * A pair of [inputs, outputs], or 0 for null. This is stored in the search index.
|
266 | 276 | * The JavaScript deserializes this into FunctionSearchType.
|
|
0 commit comments