自动管理导入或重构模块的脚本 [英] scripts to automatically manage imports or refactor modules

查看:75
本文介绍了自动管理导入或重构模块的脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人知道管理Haskell进口的工具吗?有时候,我想通过将它们移动到另一个文件来重构事物,并且一个脚本(用于为新文件生成最少的导入集)会很好.

Does anyone know of tools to manage Haskell imports? Sometimes, I want to refactor things by moving them to another file, and a script to generate the minimal set of imports [for the new file] would be nice.

推荐答案

GHC可以告诉您需要哪些导入;只需添加-fwarn-unused-imports标志.

GHC can tell you which imports are required; simply add the -fwarn-unused-imports flag.

这篇关于自动管理导入或重构模块的脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆