From 95d50f453ec519535453ec8eb290deff0a81ef02 Mon Sep 17 00:00:00 2001 From: Colin Woodbury Date: Thu, 19 Dec 2024 09:40:51 +0900 Subject: [PATCH] Fix formatting of `gethash` examples --- docs/chap-18/bi-c-dictionary/_gethash_accessor.md | 8 +++----- docs/chap-18/bi-c-dictionary/gethash_accessor.md | 5 ++++- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/docs/chap-18/bi-c-dictionary/_gethash_accessor.md b/docs/chap-18/bi-c-dictionary/_gethash_accessor.md index 6317d6692..8ab4407b0 100644 --- a/docs/chap-18/bi-c-dictionary/_gethash_accessor.md +++ b/docs/chap-18/bi-c-dictionary/_gethash_accessor.md @@ -8,12 +8,10 @@ gethash *key hash-table* &optional *default → value, present-p* - - -**(setf (gethash** *key hash-table* &optional *default***)** *new-value***)** - - +``` +(setf (gethash key hash-table &optional default) new-value) +``` **Arguments and Values:** diff --git a/docs/chap-18/bi-c-dictionary/gethash_accessor.md b/docs/chap-18/bi-c-dictionary/gethash_accessor.md index 1e33c85d2..26f5453e1 100644 --- a/docs/chap-18/bi-c-dictionary/gethash_accessor.md +++ b/docs/chap-18/bi-c-dictionary/gethash_accessor.md @@ -15,5 +15,8 @@ TODO: Please contribute to this page by adding explanations and examples ::: ```lisp -(gethash ) +(let ((ht (make-hash-table :test #'equal))) + (setf (gethash :foo ht) 1) + (gethash :foo ht)) +;; => 1, T ```