Fix const examples (#7610)

# Description

Fix const examples

# Tests + Formatting

Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect` to check that you're using the standard code
style
- `cargo test --workspace` to check that all tests pass
This commit is contained in:
Justin Ma 2022-12-27 15:44:03 +08:00 committed by GitHub
parent b4c5693ac6
commit 38fc42d352
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -72,12 +72,12 @@ impl Command for Const {
vec![
Example {
description: "Create a new parse-time constant.",
example: "let x = 10",
example: "const x = 10",
result: None,
},
Example {
description: "Create a composite constant value",
example: "let x = { a: 10, b: 20 }",
example: "const x = { a: 10, b: 20 }",
result: None,
},
]