dongtun2459 2014-02-27 17:58
浏览 268
已采纳

gofmt非常慢地完成

I'm on an iMac 27'' late 2013 model and I want to run the gofmt tool against my package.

I'm calling it like so:

iMacs-Image:sergiotapia ~/smitego $ gofmt

And it's frozen there forever, never completing. Any suggestions?

  • 写回答

1条回答 默认 最新

  • douai2499 2014-02-27 18:01
    关注

    You're calling it incorrectly. gofmt expects a source file on its standard input and outputs formatted code on standard output. Use go fmt (with a space) inside the directory of the package you want to format to format the code inside a package.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 MCNP里如何定义多个源?
  • ¥20 双层网络上信息-疾病传播
  • ¥50 paddlepaddle pinn
  • ¥20 idea运行测试代码报错问题
  • ¥15 网络监控:网络故障告警通知
  • ¥15 django项目运行报编码错误
  • ¥15 请问这个是什么意思?
  • ¥15 STM32驱动继电器
  • ¥15 Windows server update services
  • ¥15 关于#c语言#的问题:我现在在做一个墨水屏设计,2.9英寸的小屏怎么换4.2英寸大屏