$darkmode
Elektra 0.11.0
Macros
kdbmacros.h File Reference

Macros by Elektra. More...

This graph shows which files directly or indirectly include this file:

Macros

#define ELEKTRA_QUOTE(x)   #x
 Surround a value with double quotes.
 
#define ELEKTRA_STRINGIFY(x)   ELEKTRA_QUOTE (x)
 Surround a macro value with double quotes.
 
#define ELEKTRA_CONCAT2(X, Y)   X##Y
 Concat two values.
 
#define ELEKTRA_CONCAT(X, Y)   ELEKTRA_CONCAT2 (X, Y)
 Concat two macro values
 
#define ELEKTRA_SET_ERROR_READ_ONLY(info, returned, error)
 Sets error if info != returned. More...
 
#define ELEKTRA_SYMVER(sym, impl)   sym##_##impl
 Helper macro to create a versioned name of a symbol. More...
 
#define ELEKTRA_SYMVER_DECLARE(ver, sym, impl)   ELEKTRA_SYMVER_COMMAND (ELEKTRA_STRINGIFY (ELEKTRA_SYMVER (sym, impl)), #sym "@" ver)
 Declares another version of a symbol using the .symver assembler pseudo command. More...
 

Detailed Description

Macros by Elektra.

Macros start with ELEKTRA_ and are uppercase.

Macro Definition Documentation

◆ ELEKTRA_SET_ERROR_READ_ONLY

#define ELEKTRA_SET_ERROR_READ_ONLY (   info,
  returned,
  error 
)

Sets error if info != returned.

Parameters
infohow the info is now (freshly received)
returnedhow the info passed from user is
errorkey to set error to
Returns
with -1 on error

◆ ELEKTRA_SYMVER

#define ELEKTRA_SYMVER (   sym,
  impl 
)    sym##_##impl

Helper macro to create a versioned name of a symbol.

Parameters
symunversioned name of the symbol
implversion suffix

◆ ELEKTRA_SYMVER_DECLARE

#define ELEKTRA_SYMVER_DECLARE (   ver,
  sym,
  impl 
)    ELEKTRA_SYMVER_COMMAND (ELEKTRA_STRINGIFY (ELEKTRA_SYMVER (sym, impl)), #sym "@" ver)

Declares another version of a symbol using the .symver assembler pseudo command.

Parameters
verthe version name as declared versions.def
symthe unversioned name of the symbol
implthe version suffix to use for this version