TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Open source style checker for Objective C

35 点作者 rwalker将近 12 年前

8 条评论

rwalker将近 12 年前
I&#x27;m a big believer in automating process where possible - instead of trying to remember style rules or dealing with inconsistent code across a codebase, just write a script to deal with it!<p>This one was particularly fun to write because it was an excuse to use the awesome parcon library (<a href="http://www.opengroove.org/parcon/parcon-tutorial.html" rel="nofollow">http:&#x2F;&#x2F;www.opengroove.org&#x2F;parcon&#x2F;parcon-tutorial.html</a>)
评论 #5965192 未加载
zbowling将近 12 年前
Been doing something like this but instead of a custom parser, I&#x27;ve been building it against clang&#x27;s own AST instead of reinventing the wheel.
评论 #5965321 未加载
Zev将近 12 年前
Neat. Playing with parsers is fun!<p>FWIW, a similar tool exists that works with most C-style languages, `uncrustify`. Might be worth looking into as well?<p><a href="http://uncrustify.sourceforge.net" rel="nofollow">http:&#x2F;&#x2F;uncrustify.sourceforge.net</a>
评论 #5964246 未加载
revetkn将近 12 年前
This reminds me that it&#x27;s 2013 and Xcode still doesn&#x27;t have a built-in code formatter :(
评论 #5964645 未加载
bla2将近 12 年前
Or use a tool that fixes your style instead of just listing errors: <a href="http://clang.llvm.org/docs/ClangFormat.html" rel="nofollow">http:&#x2F;&#x2F;clang.llvm.org&#x2F;docs&#x2F;ClangFormat.html</a>
jgh将近 12 年前
While I can appreciate style guidelines for code, I can&#x27;t help but feel like this level of pedantry is excessive and probably a total waste of time in most cases.
评论 #5964058 未加载
评论 #5964052 未加载
评论 #5964079 未加载
marksands07将近 12 年前
clang-format exists to do the same thing <a href="http://clang.llvm.org/docs/ClangFormat.html" rel="nofollow">http:&#x2F;&#x2F;clang.llvm.org&#x2F;docs&#x2F;ClangFormat.html</a>
natch将近 12 年前
$ pip install ocstyle -bash: pip: command not found