unnecessary constraints on some functions

未關閉 適合新手
#85 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

還沒有人認領這個 Issue。

評估

難度
2/5
預估耗時
1-3 小時
新手友好度
78/100
Issue 類型
重構
描述清晰度
描述清楚
活躍度
活躍
技術堆疊
haskell

研究方向

開啟 Prolog.Programming.Task 模組,查看 checkTask、verifyConfig 和 displaySampleSolution 的簽名;從這三者中移除 MonadRandom 約束,並從 displaySampleSolution 中移除 MonadIO 約束,然後重新建置以確認呼叫它們的程式碼都不會出錯。對於第二部分,在 cabal 檔案的 ghc-options 中新增 -Wredundant-constraints(注意它不在 -Wall 中),並處理它回報的警告。完成意味著專案仍然可以建置,並且理想情況下,在乾淨的建置下該警告處於開啟狀態。

由索引模型根據 Issue 內容生成。

描述

In Prolog.Programming.Task there are three functions with superfluous constraints: checkTask, verifyConfig and displaySampleSolution. All of them have an unused MonadRandom constraint, while displaySampleSolution also has MonadIO, even though there is no IO being carried out.

There might be more such cases that I did not notice yet. It might be worthwile to enable -Wredundant-constraints to catch all instances of that problem. That warning is not enabled by -Wall.

主要語言
Haskell
星號
0
分支
1
平均合併
4 天 16 小時
30 天內合併 PR
14

環境準備

  • 沒有 Dockerfile 或 Docker Compose 檔案
  • 有 Pull Request 範本
  • 沒有貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

fmidue/prolog-programming-task 的其他 Issue

查看 fmidue/prolog-programming-task 的全部 Issue

相似的 Issue

更多 Haskell Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。