编码标准对纯C(不是C ++) [英] Coding Standards for pure C (not C++)

查看:137
本文介绍了编码标准对纯C(不是C ++)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我来自一个Java的背景(从我的CS类)和C的一个学期++。我只是完成了我的合作社这是纯C一OpenCV的项目,所以我在问这个问题迟到了一点。

I come from a java background (from my CS classes) and a semester of C++. I am just finishing up a OpenCV project for my Co-Op that's in pure C, so I'm a bit late in asking this question.

什么是设计流程和编码标准的纯C?

我熟悉面向对象编程,设计和最佳实践。我只是有点在像在C.非面向对象语言的每一个变量和函数似乎是全球亏损。这使得它感觉像一个真正的混乱给我。

I'm familiar with object oriented programming, design and best practices. I'm just a bit at a loss at a non-object oriented language like C. Every single variable and function appears to be global. It makes it feel like a real mess to me.

推荐答案

您可能有兴趣在检查出的答案到的类似的问题我问不是很久以前。此外,如果你有兴趣用C风格指南,你可能想看看此页面自它是C(和C ++)风格指南的存储库。如果你的心情了开怀大笑是,请大家看的 NASA空调风格指南。特别是,看看在的大规模的意见......你会知道我说的是哪一个。不要写这样的评论吧。

You may be interested in checking out the answers to a similar question I asked not too long ago. Moreover, if you're interested in C style guides, you may want to take a look at this page since it is a repository for C (and C++) style guides. If you're in the mood for a good laugh, please take a look at the NASA C Style Guide. In particular, take a look at the massive comment... you'll know which one I'm talking about. Don't write comments like this please.

我个人reccomend href=\"http://www.chris-lott.org/resources/cstyle/indhill-cstyle.pdf\">印山空调风格指南一些修改的 I2C接口和实现如果您无法在设计大型在C程序。

I personally reccomend the Indian Hill C Style Guide with some modifications. Furthermore, you may want to purchase the book C Interfaces and Implementations if you're having trouble designing large-scale programs in C.

这篇关于编码标准对纯C(不是C ++)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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