Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options questions only not deleted user 304
6 votes
1 answer
1k views

Why does calling expand-file-name indirectly produce a different result?

Running the following in ielm in emacs -Q: ELISP> (defun wh/expand-file-name (name &optional default-directory) (expand-file-name name default-directory)) wh/expand-file-name ELISP> (expand-file-na …
Wilfred Hughes's user avatar
4 votes
1 answer
369 views

How do I temporarily mock a function for testing?

I'd like to patch some elisp functions inside my unit tests. I've tried cl-labels and cl-flet, but neither achieve the result I want: (defun return-number () 1) (defun calls-return-number () (re …
Wilfred Hughes's user avatar