Skip to content

Instantly share code, notes, and snippets.

@svetlyak40wt
Created February 4, 2019 13:56
Show Gist options
  • Save svetlyak40wt/813e77e218d49ff9ed9204a2a13e7c01 to your computer and use it in GitHub Desktop.
Save svetlyak40wt/813e77e218d49ff9ed9204a2a13e7c01 to your computer and use it in GitHub Desktop.
;; Example of Lisp-2 behaviour of the Common Lisp
(flet ((plus (item)
(list item :flet)))
(let ((plus (lambda (item)
(list item
:lambda))))
(values
(mapcar plus
(list 1 2 3))
(mapcar #'plus
(list 1 2 3)))))
;; This should return two lists:
((1 :LAMBDA) (2 :LAMBDA) (3 :LAMBDA))
((1 :FLET) (2 :FLET) (3 :FLET))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment