Re: LISP Error in function: lsp_defatom_ex(): Duplicate key

#3
I found the problem! YESSSSSSS! and can be reproduce.
Please look the following examples:
;;first example works fine.
;; copy from the next line

(defun c:my:prompt2(a b c d e f g h i j k l)
(my:prompt a b c d e f g h i j k l)
)
(defun my:prompt(a b c d e f g h i j k l / OLDORTHO DV:OLDLAYER PT
ANG SYMBOL_SCL OLDATTREQ OLDTEXTEVAL
OLDORTHO OLDATTDIA OLANGBASE OLDANGDIR
OLDOSMODE OLDINSUNITS I:XROT N:SCL)
(prompt (itoa a))
(prompt (itoa b))
(prompt c)
(if d (prompt d))
(prompt e)
(prompt (itoa f))
(prompt (itoa g))
(if h (prompt h))
(if i (prompt i))
(prompt j)
(prompt (itoa k))
(prompt (itoa l))
)
(c:my:prompt2 0 0 "PTREE5" nil "SYMBOL" 0 1 nil nil "TREE" 240 0)

;; up to the previous line and paste it in to the command line
;; you will se that the function works fine
;;
;;
;; but now, to see how everything change, do the same with the following example:

(defun c:my:prompt2(MIRRMODE ATTDIAMODE SYMBOL FACTSYMBOL
TXTSYMBOL INSMODE ROT_MODE INSPOINT
SECONDSYM LAYER SYMB_SCALE ROT_ANG)
(my:prompt MIRRMODE ATTDIAMODE SYMBOL FACTSYMBOL
TXTSYMBOL INSMODE ROT_MODE INSPOINT
SECONDSYM LAYER SYMB_SCALE ROT_ANG)
)
(defun my:prompt(MIRRMODE ATTDIAMODE SYMBOL FACTSYMBOL
TXTSYMBOL INSMODE ROT_MODE INSPOINT
SECONDSYM LAYER SYMB_SCALE ROT_ANG / OLDORTHO DV:OLDLAYER PT
ANG SYMBOL_SCL OLDATTREQ OLDTEXTEVAL
OLDORTHO OLDATTDIA OLANGBASE OLDANGDIR
OLDOSMODE OLDINSUNITS I:XROT N:SCL)
(prompt (itoa MIRRMODE))
(prompt (itoa ATTDIAMODE))
(prompt SYMBOL)
(if FACTSYMBOL (prompt FACTSYMBOL))
(prompt TXTSYMBOL)
(prompt (itoa INSMODE))
(prompt (itoa ROT_MODE))
(if INSPOINT (prompt INSPOINT))
(if SECONDSYM (prompt SECONDSYM))
(prompt LAYER)
(prompt (itoa SYMB_SCALE))
(prompt (itoa ROT_ANG))
)
(c:my:prompt2 0 0 "PTREE5" nil "SYMBOL" 0 1 nil nil "TREE" 240 0)

;;
;;
in conclusion the problem is with the names of the variables. simple names, no problem, longer names=error
Please let me know when you fix this error. I have too much work to do and this is an unexpected inconvenience.
Thank you for listen.
Sincerely, Miguel
please