SymbolTableBuilder.addSymbol

size_t addSymbol(uint name, ulong value, ulong size, types.SymbolBinding binding, types.SymbolType type, ushort section, types.SymbolVisibility visibility = types.SymbolVisibility.DEFAULT)

Add a symbol to the symbol table.

If the symbol is local, it is added before all global symbols. If the symbol is global or weak, it is added after all local symbols.

Parameters

nameThe symbol name (string table index).
valueThe symbol's value/address.
sizeThe symbol's size.
bindingThe symbol's binding.
typeThe symbol's type.
sectionThe section index or special value.
visibilityThe symbol's visibility (default).

Returns

The symbol's index in the table.