File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -61,14 +61,20 @@ whose car is KEY. Comparison is done with `equal'."
6161 (member key (nrepl-dict-keys dict)))
6262
6363(defun nrepl-dict-get (dict key &optional default )
64- " Get from DICT value associated with KEY, optional DEFAULT if KEY not in DICT.
65- If dict is nil, return nil. If DEFAULT not provided, and KEY not in DICT,
66- return nil. If DICT is not an nREPL dict object, an error is thrown."
64+ " Get from DICT value associated with KEY.
65+ If DICT is nil, return nil.
66+ If DICT is not an nREPL dict object, an error is thrown.
67+
68+ If KEY is not in DICT, return DEFAULT (if provided).
69+ Note that the use of DEFAULT is deprecated and will be
70+ removed in a future release."
71+ (declare (advertised-calling-convention (dict key) " 1.16" ))
6772 (when dict
6873 (if (nrepl-dict-p dict)
6974 ; ; Note: The structure of the following expression avoids the
7075 ; ; expensive containment check in nearly all cases, see #3717
7176 (or (lax-plist-get (cdr dict) key)
77+ ; ; TODO: remove DEFAULT argument and the following clause
7278 (when default
7379 (and (not (nrepl-dict-contains dict key))
7480 default )))
You can’t perform that action at this time.
0 commit comments