distortos  v0.6.0
object-oriented C++ RTOS for microcontrollers
BIND_LOW_LEVEL_PREINITIALIZER.h File Reference

BIND_LOW_LEVEL_PREINITIALIZER() macro. More...

Include dependency graph for BIND_LOW_LEVEL_PREINITIALIZER.h:

Go to the source code of this file.

Macros

#define BIND_LOW_LEVEL_PREINITIALIZER(priority, function)   BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION(priority, function, ".low_level_preinitializers.")
 Binds function as low-level preinitializer with specified order. More...
 

Detailed Description

BIND_LOW_LEVEL_PREINITIALIZER() macro.

Author
Copyright (C) 2018 Kamil Szczygiel http://www.distortec.com http://www.freddiechopin.info
License
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.

Macro Definition Documentation

◆ BIND_LOW_LEVEL_PREINITIALIZER

#define BIND_LOW_LEVEL_PREINITIALIZER (   priority,
  function 
)    BIND_LOW_LEVEL_INITIALIZER_IMPLEMENTATION(priority, function, ".low_level_preinitializers.")

Binds function as low-level preinitializer with specified order.

Low-level preinitializers are executed before .bss and .data sections' initialization, before constructors for global and static objects. They are automatically executed in ascending order of order. When there is a group of multiple low-level preinitializers with the same order, the execution order within that group is unspecified.

Parameters
[in]orderis an order of the low-level preinitializer, [0; 99]
[in]functionis the low-level preinitializer function