From bc5830ca3cadaa89f7d0a262b610c23af6782e18 Mon Sep 17 00:00:00 2001 From: Daniel Perez Date: Fri, 26 Jul 2024 19:09:07 +0100 Subject: [PATCH] Add docs for underscore value --- docs/src/SUMMARY.md | 2 +- .../{builtin_functions.md => builtin_values.md} | 14 +++++++++++++- 2 files changed, 14 insertions(+), 2 deletions(-) rename docs/src/{builtin_functions.md => builtin_values.md} (97%) diff --git a/docs/src/SUMMARY.md b/docs/src/SUMMARY.md index 3b92e8c..bbd9688 100644 --- a/docs/src/SUMMARY.md +++ b/docs/src/SUMMARY.md @@ -18,5 +18,5 @@ # Reference -- [Builtin values](./builtin_functions.md) +- [Builtin values](./builtin_values.md) - [Builtin methods](./builtin_methods.md) diff --git a/docs/src/builtin_functions.md b/docs/src/builtin_values.md similarity index 97% rename from docs/src/builtin_functions.md rename to docs/src/builtin_values.md index ece2a5d..61cdb4e 100644 --- a/docs/src/builtin_functions.md +++ b/docs/src/builtin_values.md @@ -1,6 +1,18 @@ # Builtin values -## Global functions +## Globals + +### `_` + +The underscore `_` variable stores the result of the last expression evaluated. + +```javascript +>> 1 + 1 +2 +>> _ +2 +``` + ### `keccak256(bytes data) -> bytes32`