mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-26 13:03:31 +00:00
Make maxLength nullable again
This commit is contained in:
parent
58248e24cd
commit
a153b90875
2 changed files with 6 additions and 3 deletions
|
@ -318,7 +318,10 @@
|
||||||
"description": "Whether to show function parameter name inlay hints at the call site"
|
"description": "Whether to show function parameter name inlay hints at the call site"
|
||||||
},
|
},
|
||||||
"rust-analyzer.inlayHints.maxLength": {
|
"rust-analyzer.inlayHints.maxLength": {
|
||||||
"type": "integer",
|
"type": [
|
||||||
|
"null",
|
||||||
|
"integer"
|
||||||
|
],
|
||||||
"default": 20,
|
"default": 20,
|
||||||
"minimum": 0,
|
"minimum": 0,
|
||||||
"exclusiveMinimum": true,
|
"exclusiveMinimum": true,
|
||||||
|
|
|
@ -8,7 +8,7 @@ const RA_LSP_DEBUG = process.env.__RA_LSP_SERVER_DEBUG;
|
||||||
export interface InlayHintOptions {
|
export interface InlayHintOptions {
|
||||||
typeHints: boolean;
|
typeHints: boolean;
|
||||||
parameterHints: boolean;
|
parameterHints: boolean;
|
||||||
maxLength: number;
|
maxLength: number | null;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface CargoWatchOptions {
|
export interface CargoWatchOptions {
|
||||||
|
@ -160,7 +160,7 @@ export class Config {
|
||||||
return {
|
return {
|
||||||
typeHints: this.cfg.get("inlayHints.typeHints") as boolean,
|
typeHints: this.cfg.get("inlayHints.typeHints") as boolean,
|
||||||
parameterHints: this.cfg.get("inlayHints.parameterHints") as boolean,
|
parameterHints: this.cfg.get("inlayHints.parameterHints") as boolean,
|
||||||
maxLength: this.cfg.get("inlayHints.maxLength") as number,
|
maxLength: this.cfg.get("inlayHints.maxLength") as null | number,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
get excludeGlobs() { return this.cfg.get("excludeGlobs") as string[]; }
|
get excludeGlobs() { return this.cfg.get("excludeGlobs") as string[]; }
|
||||||
|
|
Loading…
Reference in a new issue