anchor.diff:  ;;; ConvertLayerSetFile.LSP -- Custom command designed to convert ls3 files into las files.
  -;;
  +;;;
   ;;; Copyright (C) 2016, Creative Commons License.
   ;;;
   ;;; Author: Szabolcs Pasztor <szabolcs1992@gmail.com>
  
positive.code:                        2 = Bad value for a state (i.e. color > 255)
    """
    (while (not (equal raw_string "\n"))
      (setq ls3_state (append ls3_state (_READ_TO_DELIMITER raw_stringe 09)))
      )
    (_LS3_STATE_CHECK_FOR_ERROR ls3_state)
    )
  
  (defun _LS3_STATE_CHECK_FOR_ERROR (ls3_state / has_error )
    )
  
  (defun _LAS_STATE_FROM_LS3 (ls3_state)
  
negative.code: ;;; ---------------------------------------------------------------------------
  ;;; Helper Function(s):
  ;;; ---------------------------------------------------------------------------
  (defun GET_FIRST_N (lst n_max / n)
    "Returns the first n_max elements of a list."
     (setq n -1)
     (repeat (>= n (- n_max 1))
       (progn
         (1+ n)
         (append (nth n lst))
         )
       )
    )
  
  (defun REPLACE_N (lst new_value nth_element )
    "Returns a list with the n'th_element replaced with new_value"
    (append
      (GET_FIRST_N lst (- nth_element 1))
      new_value
      (GET_FIRST_N (reverse lst) (- (length lst) nth_element))
      )
    )
  
  (defun _READ_TO_DELIMITER (raw_string delimiter_character_code / parsed_string delimiter_position)
    "Returns the string up to delimiter_code and removes it from raw_string."
    (setq delimiter_position (vl-string-position delimiter_character_code raw_string))
  