I'm having difficulty to call a function passed as an argument. Why the following snippet doesn't work, and how can I make it work?
lexical-binding is set to
(defun on-success (data) (print "This works!") (print data)) (defun send-req (url callback) (request url :success (function* (lambda (&key data &allow-other-keys) (print (type-of callback) ; <- this prints 'symbol', without lexical binding it would be nil (funcall 'callback data))))) (defun foo () (send-req "https://google.com" 'on-success)) (foo)