The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (Linux)
File Line Function
/showthread.php 795 errorHandler->error





Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Coding style guidelines?
05-31-2013, 04:05 PM (This post was last modified: 05-31-2013 04:07 PM by TheDax.)
Post: #1
Coding style guidelines?
Do we have a written set of coding style guidelines anywhere for PPSSPP? I'm noticing a lot of inconsistencies in how the code is laid out, in files such as sceNet.cpp and sceIo.cpp. I'm guilty of it too, since I'm unsure of how the code should be styled.

For example:
u32 sceNetAdhocInit() {
//... body omitted
}

versus

u32 sceWlanGetEtherAddr(u32 addrAddr)
{
//...body omitted
}

Should braces be on a new line(that's how I prefer it, but I can change for contributing.. <_<) or on the same line as a function declaration/if statement?

Also, how about comments?

Is this prefered:
//Line 1
//Line 2
//Line 3

Or this?
/*Line 1
*Line 2
*Line 3*/
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Coding style guidelines? - TheDax - 05-31-2013 04:05 PM
RE: Coding style guidelines? - Apology11 - 05-31-2013, 05:44 PM
RE: Coding style guidelines? - [Unknown] - 05-31-2013, 05:45 PM
RE: Coding style guidelines? - TheDax - 05-31-2013, 06:37 PM

Forum Jump: