You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/01/11 14:01:44 UTC

[GitHub] [incubator-nuttx] patacongo edited a comment on issue #79: An idea to reduce duplicate code in ./boards/.

patacongo edited a comment on issue #79: An idea to reduce duplicate code in ./boards/.
URL: https://github.com/apache/incubator-nuttx/issues/79#issuecomment-573319328
 
 
   I am opposed to these kinds of changes.  The board directories  are customization points and MUST NOT BE MERGED INTO COMMON FILES.  That corrupts the modulare architecture of the OS and cannot be permitted.
   
   There are things that are common not particularly customization points (like some USB Host logic).  But I would resist strong any willy nilly combination of code just because it looks the same today (it might look different tomorrow, that is the nature of customization points).
   
   I would refer you to the top-level INVIOLABLES.txt under "The Enemies."
   
   109 Sometimes Code Duplication is OK
   110 --------------------------------
   111
   112   o Sometimes is better to duplicate some logic than to introduce coupling
   
   Any rampant combination of logic for now reason than the OCD compulsion to due so must be resisted.  What you are proposing WILL damage the OS.
   
   Autoleds, in particular, must not be combined!
   
   Anyone who supports this proposal has no sense or understanding of the NuttX architecture or modularity goals.  This would an absolute disaster for the OS!

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services