Luxoft / iviLink

iviLINK application connectivity stack for in-vehicle infotainment
16 stars 6 forks source link

Code guidelines #2

Closed tim-oleksii closed 12 years ago

tim-oleksii commented 12 years ago

Hello,

Do you have any coding styles?

I see that you've got a couple of styles like


std::list <std::string> ReadFile(const std::string name);

AND

CError NegotiateChannel(std::string tag, UInt32 & channelId);

What is more, sometimes I encounter tabs, sometimes spaces.

Secondly, are there any agreements what should be used for a project? For instance, exception free libraries, pthread as a library from ITC etc.

kostiakhait commented 12 years ago

Hello Oleksii,

  1. Yes, we use the code style. But we don’t manage minor things like tabs and spaces, at least we don’t do it mandatory.
  2. No, we don’t use exceptions. Using exceptions in embedded systems is often too expensive from resource perspective, therefore we avoid it. It is not a policy, but strict recommendation.
  3. We freely use MIT and LGPL components, using of other ones needs detailed legal review. We follow KISS principle and don’t use what we can avoid with minimum of extra efforts. Thanks, Kostia

Konstantin A. Khait Head of automotive R&D Technology Strategy Center Luxoft, member of IBS group 194044, Russia 47D Vyborgskaya emb. Saint-Petersburg Phone: +7 812 3331544 ext. 3436 Mobile: +7 921 9005780 Skype: kostia.khait

tim-oleksii commented 12 years ago

Konstantin, thanks for a reply.

Could you please tell where I can get the copy of code style rules?

Thnx.

kostiakhait commented 12 years ago

Sent by email, we will publish it shortly after translating in English.