Changes between Version 45 and Version 46 of MapGuideCodingStandards


Ignore:
Timestamp:
Sep 19, 2022, 6:06:00 AM (20 months ago)
Author:
jng
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • MapGuideCodingStandards

    v45 v46  
    708708}}}
    709709
    710 `auto` also has useful applications for primitive variable declarations as it can fix up to one half of any potential `data type mismatch` warnings as a result of declaring the variable with an incorrect (or insufficiently wide) type on the left-hand side of a variable assignment (think `size_t`/`int` indexing mismatches in for loops for an example)
    711 
    712 However, do not use `auto` as the return type (aka. return type deduction) in any public API method signature. We need to be as verbose and concise as possible for SWIG to generate the correct proxy classes.
     710`auto` also has useful applications for primitive variable declarations as it can fix up to one half of any potential `data type mismatch` warnings as a result of declaring the variable with an incorrect (or insufficiently wide/narrow) type on the left-hand side of a variable assignment (think `size_t`/`int` indexing mismatches in for loops for an example)
     711
     712However, do not use `auto` as the return type (aka. return type deduction) in any public API method signature. We need to be as verbose and concise as possible for SWIG to generate the correct proxy classes and their methods.
    713713
    714714==== for loops ====