小编pri*_*cks的帖子

Haskell堆栈找不到安装的ghc

已经建立的项目无法找到GHC.堆栈构建导致:

No compiler found, expected minor version match with ghc-8.0.2 (x86_64-ncurses6-nopie)
(based on resolver setting in /home/iam/Work/has/grove/stack.yaml).
To install the correct GHC into /home/iam/.stack/programs/x86_64-linux/, try running "stack
setup" or use the "--install-ghc" flag. To use your system GHC installation,
run "stack config set system-ghc --global true", or use the "--system-ghc" flag.
Run Code Online (Sandbox Code Playgroud)

堆栈设置导致:

Unable to find installation URLs for OS key: linux64-ncurses6-nopie
However, in .stack-work, in the install file there is a folder called x86_64-linux-ncurses6,
not linux64-ncurses6-nopie
Run Code Online (Sandbox Code Playgroud)

Stack由pacman安装.版本1.4.0 x86_64,该项目使用解析器:lts-8.21

linux haskell-stack

7
推荐指数
1
解决办法
580
查看次数

Android中的onViewRecycled,onDetachedFromRecyclerView和onViewDetachedFromWindow之间的区别

我在理解官方文档使用的术语时遇到了一些麻烦.具体来说,有方法 onViewRecycled,onDetachedFromRecyclerViewonViewDetachedFromWindow.这三者有什么区别?

android recycler-adapter android-recyclerview

7
推荐指数
1
解决办法
4747
查看次数

在公共 lisp 中将结构传递给宏的类型错误

我有这个结构:

(defstruct (endpoint (:constructor create-endpoint (name tags values)))
  name tags values)
Run Code Online (Sandbox Code Playgroud)

还有这个宏:

(defmacro build-get-endpoint (server db-uri db endpoint)
  "constructs a get endpoint that returns all records in the measurement"
  (with-gensyms (uri-sym path-sym query-sym route-sym fields)
    `(let ((,fields (cons "time" (append (endpoint-tags ,endpoint)
                                         (endpoint-values ,endpoint))))
           (,uri-sym (quri:uri ,db-uri))
           (,path-sym (format nil "/~a" ,(endpoint-name endpoint)))
           (,query-sym (format nil "SELECT ~{~a~^, ~} FROM ~a"
                               ,fields ,(endpoint-name endpoint))))

       (setf (quri:uri-path ,uri-sym) "/query")
       (setf (quri:uri-query-params ,uri-sym)
             (list (cons "q" ,query-sym) (cons "db" ,db)))

       (define-route ,server …
Run Code Online (Sandbox Code Playgroud)

macros struct common-lisp typeerror

1
推荐指数
1
解决办法
35
查看次数