============================= CodePeer 20 NEW FEATURES LIST ============================= Copyright (C) 2021, AdaCore This file contains a complete list of new features in version 20 of CodePeer. A full description of all CodePeer features can be found in the CodePeer documentation. An ISO date (YYYY-MM-DD) appears in parentheses after the description line. This date shows the implementation date of the feature. Any 20.0w wavefront subsequent to this date will contain the indicated feature, as will any subsequent 20 or later release. NF-S919-027 Improved pretty-printing of floating-point ranges (2019-09-19) Inside check messages, CodePeer will display floating-point ranges in a more readable way, using either reasonably-sized rationals, or rounded values written using scientific notation. NF-S521-054 Enhanced return codes (2019-06-11) CodePeer now returns a nonzero return code only in the presence of unexpected errors. Reaching internal tool limits is expected, especially for large code bases, so nonzero return codes are no longer returned when only internal tool limits are hit. NF-S507-042 Reproducible runs at level 3 (2019-06-17) When running CodePeer at level 3, the same partition size is now chosen, independently of the memory available on the machine. This change coupled with the previous introduced "steps" limit provides reproducible runs when switching from one machine to another. The default is to create partitions for up to 4GB of memory. This can be overriden via the new switch -partition-memory-limit. NF-S319-019 Improved menu CodePeer>Advanced>Remove Lock (2019-09-12) When using the GNAT Studio menu CodePeer>Advanced>Remove Lock, the Sqlite.db.lock file is deleted, in addition to the inspector.lock file. NF-S223-008 Excluded_Source_Files for files in subprojects (2019-02-26) The project attribute Excluded_Source_Files can now be used in the root project to specify files in subprojects and exclude the corresponding files from analysis, instead of generating a warning and not excluding them. NF-S208-036 Better analysis of formals when Address is evaluated (2019-03-25) In the past, CodePeer would sometimes deduce incorrect conclusions about a formal parameter of a subprogram whose Address attribute is referenced. For example, an out-mode parameter which is initialized by passing its address to some other subprogram might have been incorrectly flagged as having not been initialized. CodePeer's analysis in such situations is now more conservative. This results in fewer high-severity false positive messages and brings CodePeer's treatment of formal parameters into line with CodePeer's longstanding treatment of other objects (e.g., local variables) in analogous cases. NF-S204-015 Improve documentation on Accessibility_Level (2019-02-27) The notation X'Accessibility_Level from CodePeer's output is now documented in the user guide. Filtering is also improved to capture more cases of possible false positives about accessibility level when using -messages min/normal. NF-S125-051 More information when interrupting an analysis (2019-02-08) When interrupting a CodePeer run with Ctrl-C, the name of the file(s) being analyzed when interrupted is displayed, to give more information on where the analysis was. NF-S115-004 Better performance in the presence of unknown calls (2019-05-27) The performance in the presence of calls to unknown targets has been improved, in particular in cases where these calls are made inside conditional branches. NF-S114-009 Improved presumptions for some calls (2019-03-27) When analyzing a call to a subprogram whose body is unavailable (often due to partitioning), CodePeer makes presumptions about the effects of the call (e.g., about which, if any, global variables are modified by the call). In the case of an instance of Unchecked_Deallocation, or of certain subprograms implicitly generated by the compiler, information about the subprogram may be known even though the body is unavailable. CodePeer now makes better use of this information in determining the possible side effects of a call. NF-RB30-025 Improved display of values in GPS tooltips (2018-12-01) In the GPS source editors, the tooltips displaying possible values of variables computed by CodePeer have been improved, with tooltips appearing in more places. NF-RB12-034 GPR_TOOL environment variable set by CodePeer (2018-11-12) If not already set, the GPR_TOOL environment variable is now set by CodePeer automatically to "codepeer", allowing for instance to reference this variable from project files via e.g. Tool := External ("GPR_TOOL"); NF-R913-009 More precise handling of unknown and recursive calls (2018-12-21) CodePeer is more precise in its handling of calls to targets that are not analyzed but are known as having no side effects other than modifying their output parameters. This includes in particular calls to the Ada run-time library. Moreover, CodePeer is more precise when handling recursive calls. It avoids overly conservative assumptions when handling a call to a target that has not yet been analyzed but will be analyzed later. NF-R907-037 Make non-local variables updatable by unknown calls (2019-05-09) Variables which are declared globally to the subprogram making a call to an unknown target are now always assumed to be possibly updatable by this unknown target. This means that CodePeer now generates presumptions about values of these variables after the call avoiding high severity false positive warnings which would be generated when CodePeer would assume that these variables cannot be modified by the call. NF-R817-025 New pragma Annotate / Modified (2019-09-24) The pragma Annotate / Modified can be used to tell CodePeer to assume that (at the point where the pragma is placed) a given object is fully initialized and that nothing else should be assumed about the value of that object; any previous deductions CodePeer may have made about the value of the object at the point of the pragma should be discarded. This pragma is intended for working around situations where CodePeer becomes confused about the value of a variable at some point in a program and consequently generates incorrect messages. NF-R713-037 Display of message IDs in GPS (2018-11-29) A new GPS preference is available to optionally display the id of codepeer messages in the locations view and allow search/filter on them. NF-R427-018 Generate preconditions that depend on 'Valid (2018-11-13) The handling of 'Valid was changed in order to enable generation of preconditions for checks that depend on 'Valid. Before the change, if some check depended on 'Valid and there existed an input of an analyzed subprogram that could cause the check to fail, a message that the check may fail was always emitted, whereas now a precondition of the subprogram that restricts the input of the subprogram in order to pass the check is generated. NF-R405-035 Better detection of "really constant" variables (2019-03-04) In some cases where an object is declared as a variable but is, in effect, a constant (for example, the addition of the keyword "constant" would not have caused the program to become illegal), CodePeer detects this situation earlier than before and uses this information in CodePeer's analysis. For example, during the analysis of a subprogram that refers to the object but which does not enclose the declaration of the object (that is, a subprogram that makes an up-level reference to the object), this may allow CodePeer to know the value of the object in cases where it previously did not. NF-Q922-026 CodePeer --help output available in GPS (2018-12-14) The codepeer switches summary displayed by codepeer --help is now available in GPS as part of the interactive dialog display for the various CodePeer menus (e.g. CodePeer>Analyze...). NF-Q809-007 Improve handling of uplevel constant arrays (2018-11-27) CodePeer now has a more precise tracking of uplevel constant array values (a constant is uplevel w.r.t. a procedure if it is declared outside of the procedure but the procedure is in the scope of the constant), this results in less false positive messages. NF-Q601-024 Improved pretty-printing of integer ranges (2019-01-03) CodePeer will now display in a simpler way integer ranges whose complement is a single integer. NF-Q516-027 Manual reviews better highlighted in GPS Locations (2018-12-06) The CodePeer messages that have been reviewed by users now have a review icon of a different color indicating the state of the last review. The associated tooltip also includes the review status information, and the text of the messages reviewed as "not a bug" are also displayed with a different color. NF-Q515-036 Custom message review status (2019-12-17) Users can now define their own custom review status to manually triage CodePeer messages. NF-Q328-011 Improve processing of messages from database (2019-01-09) Processing of messages comming from the database has been improved. In practice this means that the CodePeer report window in GPS is faster to load messages. It also means that the output of messages is faster when using -output-msg. NF-Q314-043 Display count of analyzed subprograms (2018-11-28) CodePeer now reports the number of subprograms that were successfully analyzed in the summary information at the completion of analysis and in the Inspection.log file. NF-Q302-040 Project switches displayed in GPS interactive dialog (2018-12-14) When using the CodePeer interactive dialogs such as Analyze... or Analyze File by File... the project switches are now displayed to ease interactive selection of extra switches. NF-Q215-015 Emit "call too complex" in Inspection.log (2018-10-19) CodePeer now outputs a "call too complex" tool limitation in the Inspection.log file, when it prematurely stops analyzing a call due to its complexity. NF-P915-023 Improved review of multiple CodePeer messages (2018-12-10) When manually reviewing multiple CodePeer messages at once in GPS, the dialog now displays information about the history of all messages reviewed, similarly to what is done when reviewing a single message. NF-P308-018 GPS progress bar for message generation (2018-11-15) A progress bar is now displayed in GPS when generating message output, such as for CSV.