class Array

Public Instance Methods

to_lisp() click to toggle source

Returns a string that represents the array as a lisp list.

Example:

“` [:foo, 123, “bar”].to_lisp => '(foo 123 “bar”)'

# File lib/spectator/emacs.rb, line 64
def to_lisp
  sexp_array = map { |el| el.to_lisp }
  "(#{sexp_array.join ' '})"
end