anchor.diff:      (endwin)))
   
   (defun ut02b ()
  +  "Add russian char Љ as cchar_t by manually setting it with mem-aref."
  +  (setlocale +LC-ALL+ "")
     (let ((scr (initscr)))
       (start-color)
       (init-pair 1 1 3) ; red(1) on yellow(3)
  
positive.code: ;; Unicode strings are supported by the default non-unicode ncurses API (addstr) as long as libncursesw is used.
  ;; Special wide-char string functions (addwstr, add_wchstr) do not have to be used.
  (defun ut01 ()
    (initscr)
  
    (mvaddstr 2 2 "ččććššđđžž")
  
negative.code: ;; Use the cchar type for convert-to-foreign via a plist.
  ;; cchar-chars isnt a pointer to an integer array here, but an integer.
  (defun ut02 ()
    "Display russian chars ш and Љ as cchar_t without creating it with setcchar."
    (setlocale +LC-ALL+ "")
    (let ((scr (initscr)))
  
      ;; %add-wch
      ;; Add #\CYRILLIC_SMALL_LETTER_SHA = #\ш to the stdscr.
      (cffi:with-foreign-object (ptr '(:struct cchar_t))
        (setf ptr (cffi:convert-to-foreign (list 'cchar-attr 0 'cchar-chars (char-code #\ш))
                                      '(:struct cchar)))
        (add-wch ptr))
  
      ;; %wadd-wch
      ;; #\CYRILLIC_CAPITAL_LETTER_LJE = #\Љ
      (cffi:with-foreign-object (ptr '(:struct cchar_t))
        (setf ptr (cffi:convert-to-foreign (list 'cchar-attr #x00020000 'cchar-chars (char-code #\Љ))
                                      '(:struct cchar)))
        (wadd-wch scr ptr))
  