[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

a little help with basic elisp

From: Glen Stark
Subject: a little help with basic elisp
Date: Fri, 20 Feb 2015 06:47:04 GMT
User-agent: Pan/0.139 (Sexual Chocolate; GIT bf56508 git://

Hi everyone

I'm having trouble with the basics of lisp, and I'd like some help 
understanding and correcting what I am doing wrong in the following mce:

(defun gas-push-sr-pair ()
  "I want to add a apair consisting of a the string I prompted for at the 
mini-buffer, and the string yo"
  (let (to-string)
        (setq to-string (read-from-minibuffer (concat (thing-at-point 
'symbol) " to: ")))
        (add-to-list 'gas-sr-stack  '(to-string . "yo") )

When I run this, and do   (insert (pop gas-sr-stack)), I get the 

  gas-pop-word: Wrong type argument: char-or-string-p, (to-string . "yo")

>From this I can see that I probably can't insert a char-or-string-p.  I 
guess I can figure that out -- it's not really part of my end goal 
problem anyway.

What's tripping me up is it seems that the values stored in the char-or-
string-p are to-string and "yo".

I wanted to store the value which is currently in to-string, and "yo".  

Can someone please explain to me what I am doing wrong?  I'd like to 
understand the language better, and of course solve my concrete problem.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]