unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Trouble setting a variable to a list
@ 2014-10-18  2:33 Chris Seberino
  2014-10-18  3:04 ` Drew Adams
  2014-10-18  3:10 ` Alexis
  0 siblings, 2 replies; 3+ messages in thread
From: Chris Seberino @ 2014-10-18  2:33 UTC (permalink / raw)
  To: help-gnu-emacs

I tried to set the following variable to a list of strings....

(setq buffers-to-skip
      '("*scratch*", "*Messages*", "*Echo Area 0*", "*Echo Area 1*",
                                 "*Minibuf-0*", "*Minibuf-1*", "*Buffer List*"))


When I tried to use it and debug the problem I saw the list looked like this...

("*scratch*"
 (\, "*Messages*")
 (\, "*Echo Area 0*")
 (\, "*Echo Area 1*")
 (\, "*Minibuf-0*")
 (\, "*Minibuf-1*")
 (\, "*Buffer List*"))


Why the \'s showed up?



^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: Trouble setting a variable to a list
  2014-10-18  2:33 Trouble setting a variable to a list Chris Seberino
@ 2014-10-18  3:04 ` Drew Adams
  2014-10-18  3:10 ` Alexis
  1 sibling, 0 replies; 3+ messages in thread
From: Drew Adams @ 2014-10-18  3:04 UTC (permalink / raw)
  To: Chris Seberino, help-gnu-emacs

> I tried to set the following variable to a list of strings....
> 
> (setq buffers-to-skip
>       '("*scratch*", "*Messages*", "*Echo Area 0*", "*Echo Area 1*",
>                                  "*Minibuf-0*", "*Minibuf-1*",
>                                  "*Buffer List*"))
> 
> When I tried to use it and debug the problem I saw the list looked
> like this...
> 
> ("*scratch*"
>  (\, "*Messages*")
>  (\, "*Echo Area 0*")
>  (\, "*Echo Area 1*")
>  (\, "*Minibuf-0*")
>  (\, "*Minibuf-1*")
>  (\, "*Buffer List*"))
> 
> Why the \'s showed up?

Drop the commas (,):

(setq buffers-to-skip '("*scratch*" "*Messages*" "*Echo Area 0*"
                        "*Echo Area 1*" "*Minibuf-0*" "*Minibuf-1*"
                        "*Buffer List*"))



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Trouble setting a variable to a list
  2014-10-18  2:33 Trouble setting a variable to a list Chris Seberino
  2014-10-18  3:04 ` Drew Adams
@ 2014-10-18  3:10 ` Alexis
  1 sibling, 0 replies; 3+ messages in thread
From: Alexis @ 2014-10-18  3:10 UTC (permalink / raw)
  To: help-gnu-emacs


Chris Seberino writes:

> I tried to set the following variable to a list of strings....
>
> (setq buffers-to-skip
>       '("*scratch*", "*Messages*", "*Echo Area 0*", "*Echo Area 1*",
>                                  "*Minibuf-0*", "*Minibuf-1*", "*Buffer List*"))
>
>
> When I tried to use it and debug the problem I saw the list looked like this...
>
> ("*scratch*"
>  (\, "*Messages*")
>  (\, "*Echo Area 0*")
>  (\, "*Echo Area 1*")
>  (\, "*Minibuf-0*")
>  (\, "*Minibuf-1*")
>  (\, "*Buffer List*"))
>
>
> Why the \'s showed up?

You're using commas to separate items in your list, but elements of
lists are separated by spaces. Trying removing all the commas.


Alexis.




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-10-18  3:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-18  2:33 Trouble setting a variable to a list Chris Seberino
2014-10-18  3:04 ` Drew Adams
2014-10-18  3:10 ` Alexis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).