@@ -6,6 +6,7 @@ use crate::job::Job;
66use super::*;
77
88use helix_core::fuzzy::fuzzy_match;
9+use helix_core::indent::MAX_INDENT;
910use helix_core::{encoding, line_ending, path::get_canonicalized_path, shellwords::Shellwords};
1011use helix_lsp::{OffsetEncoding, Url};
1112use helix_view::document::DEFAULT_LANGUAGE_NAME;
@@ -476,8 +477,7 @@ fn set_indent_style(
476477 cx.editor.set_status(match style {
477478 Tabs => "tabs".to_owned(),
478479 Spaces(1) => "1 space".to_owned(),
479− Spaces(n) if (2..=8).contains(&n) => format!("{} spaces", n),
480− _ => unreachable!(), // Shouldn't happen.
480+ Spaces(n) => format!("{} spaces", n),
481481 });
482482 return Ok(());
483483 }
@@ -489,7 +489,7 @@ fn set_indent_style(
489489 Some(arg) => arg
490490 .parse::<u8>()
491491 .ok()
492− .filter(|n| (1..=8).contains(n))
492+ .filter(|n| (1..=MAX_INDENT).contains(n))
493493 .map(Spaces),
494494 _ => None,
495495 };
@@ -2606,7 +2606,7 @@ pub const TYPABLE_COMMAND_LIST: &[TypableCommand] = &[
26062606 TypableCommand {
26072607 name: "indent-style",
26082608 aliases: &[],
2609− doc: "Set the indentation style for editing. ('t' for tabs or 1-8 for number of spaces.)",
2609+ doc: "Set the indentation style for editing. ('t' for tabs or 1-16 for number of spaces.)",
26102610 fun: set_indent_style,
26112611 signature: CommandSignature::none(),
26122612 },