Class: Array
Instance Method Summary collapse
-
#to_lisp ⇒ Object
Returns a string that represents the array as a lisp list.
Instance Method Details
#to_lisp ⇒ Object
Returns a string that represents the array as a lisp list.
Example:
[:foo, 123, "bar"].to_lisp => '(foo 123 "bar")'
64 65 66 67 |
# File 'lib/spectator/emacs.rb', line 64 def to_lisp sexp_array = map { |el| el.to_lisp } "(#{sexp_array.join ' '})" end |