#[repr(i32)]pub enum ExitCode {
Success = 0,
Error = 1,
}Expand description
Exit code for the LSP server process.
Per the LSP specification:
- Exit code 0 if proper
shutdown->exitsequence was followed - Exit code 1 if
exitwas received without priorshutdown
§Examples
use lsp_server_tokio::ExitCode;
let code = ExitCode::Success;
assert_eq!(code as i32, 0);
let code = ExitCode::Error;
assert_eq!(code as i32, 1);Variants§
Success = 0
Proper shutdown sequence was followed (shutdown then exit).
Error = 1
Exit without prior shutdown request.
Trait Implementations§
impl Copy for ExitCode
impl Eq for ExitCode
impl StructuralPartialEq for ExitCode
Auto Trait Implementations§
impl Freeze for ExitCode
impl RefUnwindSafe for ExitCode
impl Send for ExitCode
impl Sync for ExitCode
impl Unpin for ExitCode
impl UnsafeUnpin for ExitCode
impl UnwindSafe for ExitCode
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more