AutosarC++18_03-A18.5.1

Functions malloc, calloc, realloc and free shall not be used

Required inputs: IR

In C++, memory should be managed automatically using classes such as std::unique_ptr, std::shared_ptr and std::vector.

Note: this rule only reports the C functions,

Possible Messages

Key

Text

Severity

Disabled

stdlib_memory_function_call

Dynamic memory management function from <stdlib.h> is called.

None

False

Options

allow_in_user_new_delete_operator

allow_in_user_new_delete_operator : bool = True

Whether to allow the library functions inside user defined new/delete operator overloads.