LINT.H 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. //
  2. // Copyright 2020 Electronic Arts Inc.
  3. //
  4. // TiberianDawn.DLL and RedAlert.dll and corresponding source code is free
  5. // software: you can redistribute it and/or modify it under the terms of
  6. // the GNU General Public License as published by the Free Software Foundation,
  7. // either version 3 of the License, or (at your option) any later version.
  8. // TiberianDawn.DLL and RedAlert.dll and corresponding source code is distributed
  9. // in the hope that it will be useful, but with permitted additional restrictions
  10. // under Section 7 of the GPL. See the GNU General Public License in LICENSE.TXT
  11. // distributed with this program. You should have received a copy of the
  12. // GNU General Public License along with permitted additional restrictions
  13. // with this program. If not, see https://github.com/electronicarts/CnC_Remastered_Collection
  14. /* $Header: /CounterStrike/LINT.H 1 3/03/97 10:25a Joe_bostic $ */
  15. /***********************************************************************************************
  16. *** C O N F I D E N T I A L --- W E S T W O O D S T U D I O S ***
  17. ***********************************************************************************************
  18. * *
  19. * Project Name : Command & Conquer *
  20. * *
  21. * File Name : LINT.H *
  22. * *
  23. * Programmer : Joe L. Bostic *
  24. * *
  25. * Start Date : 03/28/96 *
  26. * *
  27. * Last Update : March 28, 1996 [JLB] *
  28. * *
  29. *---------------------------------------------------------------------------------------------*
  30. * Functions: *
  31. * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  32. // overloading data member (e.g., IsToRedraw)
  33. //lint -e1516
  34. // function distinguishing error (actually not an error when conversion operators are used).
  35. //lint -e1053
  36. /*
  37. ** The current version of Lint doesn't know how to deal with conversion operators. It
  38. ** erroneously generates this error message as a result. Unfortunately, we have to throw
  39. ** out the baby with the bathwater on this one.
  40. */
  41. //lint -e58 -e56
  42. /*
  43. ** Hiding a non virtual member function is generally ok.
  44. */
  45. //lint -e1511
  46. /*
  47. ** The warning about not initializing a member during construction is
  48. ** valid. However, C&C takes advantage of this by using the in place
  49. ** new operator during the load game process. Disable the warning, but
  50. ** grudgingly.
  51. */
  52. //lint -e1401
  53. /*
  54. ** Disable warning about non virtual base class destructor for these objects.
  55. */
  56. //lint -esym(1509,GraphicBufferClass,GraphicViewPortClass,BufferClass,VideoViewPortClass,GetCDClass)
  57. //lint -esym(1509,BasicTimerClass,FlyClass,FuseClass,StageClass,FlasherClass,CargoClass,DoorClass)
  58. //lint -esym(1509,AbstractTypeClass)
  59. /*
  60. ** The "unusual cast" warning is the result of derived casting. This is
  61. ** because there is no "dynamic_cast<>" implemented in Watcom (version 10.5).
  62. */
  63. //lint -e740 -e571
  64. /*
  65. ** "function not previously declared inline" is probably not worth noting.
  66. */
  67. //lint -e1727
  68. /*
  69. ** Allow sub-integer loss of precision. This will allow assigning ints to
  70. ** chars without warning.
  71. */
  72. //lint -e734
  73. /*
  74. ** Shifting an integer left is always ok.
  75. */
  76. //lint -e701 -e703
  77. /*
  78. ** Allow repeated include files. The body of the include file should be
  79. ** coded to ensure that it is processed only once.
  80. */
  81. //lint -e537
  82. /*
  83. ** Implicitly converting an enum to an integer is almost always ok.
  84. */
  85. //lint -e641
  86. /*
  87. ** It is possible to have template functions for "++" and "--" that
  88. ** don't require one of the parameters to be a class object.
  89. */
  90. //lint -e1042
  91. /*
  92. ** Redundant declarations are ok. They are a bit harder to maintain,
  93. ** but they facilitate keeping modules less interdependant (include
  94. ** file wise).
  95. */
  96. //lint -e963 -e762 -e763
  97. /*
  98. ** Not having a default constructor is ok.
  99. */
  100. //lint -e1712
  101. /*
  102. ** Private constructors are ok. In fact, they are necessary if the
  103. ** class object must never be instantiated outside of the class
  104. ** itself.
  105. */
  106. //lint -e1704
  107. /*
  108. ** Ignoring the return value from a function is ok. It is very
  109. ** common for certain side-effect type functions.
  110. */
  111. //lint -e534
  112. /*
  113. ** Implicitly converting from a signed to an unsigned parameter (or
  114. ** visa versa) is ok.
  115. */
  116. //lint -e732 -e502 -e713 -e737 -eau
  117. /*
  118. ** Allow functions to overload and hide base functions. This is a
  119. ** technique of inheritance that handles function parameter changes.
  120. */
  121. //lint -e1411
  122. /*
  123. ** If a switch statement doesn't have a case for every value (enums)
  124. ** but it does have a "default" case, then don't warn about it.
  125. */
  126. //lint -e788
  127. /*
  128. ** If bitwize arithmetic is performed on compatible enumeration types,
  129. ** then don't complain. Many enums are used in this fashion.
  130. */
  131. //lint -e655 -e656
  132. /*
  133. ** If a data member is not explicitly initialized in the initializer
  134. ** list, this is ok.
  135. */
  136. //lint -e1542
  137. /*
  138. ** Calling "new" when not part of an assignment operation can be valid. This
  139. ** is true if the "new" operator has been overloaded and the class keeps
  140. ** track of itself.
  141. */
  142. //lint -e522
  143. /*
  144. ** A class that is zero bytes long is ok. This is how method classes
  145. ** usually work.
  146. */
  147. //lint -e1501
  148. /*
  149. ** Boolean passed to function is ok.
  150. */
  151. //lint -e730
  152. /*
  153. ** Signed/unsigned mix with relational... ignore for now.
  154. */
  155. //lint -e574