Verify whole application
Stop verification if sources files are incomplete and
do not contain a main
function
Description
This option affects a Code Prover analysis only.
This option is not available for code generated from MATLAB® code or Simulink® models.
Specify that Polyspace® verification must stop if a main
function
is not present in the source files.
If you select a Visual C++® setting for Compiler (-compiler)
, you can specify which
function must be considered as main
. See Main entry
point (-main)
.
Set Option
User interface (desktop products only): In your project configuration, the option is on the Code Prover Verification node.
User interface (Polyspace Platform, desktop products only): In your project configuration, the option is on the Static Analysis tab on the Run Time Errors node.
Command line and options file: There is no corresponding command-line option. See Command-Line Information.
Settings
- On
Polyspace verification stops if it does not find a
main
function in the source files.- Off (default)
Polyspace continues verification even when a
main
function is not present in the source files. If amain
is not present, it generates a file__polyspace_main.c
that contains amain
function.
Tips
If you use this option, your code must contain a main
function.
Otherwise you see the error:
Error: required main procedure not found
If your code does not contain a main
function, use the option
Verify module or library (-main-generator)
to
generate a main
function.
Command-Line Information
Unlike the user interface, by default, a verification from the
command line stops if it does not find a main
function
in the source files. If you specify the option -main-generator
, Polyspace generates
a main
if it cannot find one in the source files.
See Also
Verify module or library (-main-generator)
| Show global
variable sharing and usage only (-shared-variables-mode)
Topics
- Specify Polyspace Analysis Options
- Verify C Application Without main Function (Polyspace Code Prover)
- Verify C++ Classes (Polyspace Code Prover)