package linksem

  1. Overview
  2. Docs
A formalisation of the core ELF and DWARF file formats written in Lem

Install

Dune Dependency

Authors

Maintainers

Sources

0.8.tar.gz
md5=2075c56715539b3b8f54ae65cc808b8c
sha512=f7c16e4036a1440a6a8d13707a43f0f9f9db0c68489215f948cc300b6a164dba5bf852e58f89503e9d9f38180ee658d9478156ca1a1ef64d6861eec5f9cf43d2

doc/linksem_zarith/String_table/index.html

Module String_tableSource

The string_table module implements string tables. An ELF file may have * multiple different string tables used for different purposes. A string * table is a string coupled with a delimiting character. Strings may be indexed * at any position, not necessarily on a delimiter boundary.

Sourcetype string_table =
  1. | Strings of char * string

string_table type, represents a string table with a fixed delimiting * character and underlying string.

Sourceval dummy_strtab : string_table
Sourceval mk_string_table : string -> char -> string_table

mk_string_table base sep constructs a string table using base as the * base string and sep as the delimiting character to use to split base * when trying to access the string stored in the table using the functions below.

Sourceval string_table_of_byte_sequence : Byte_sequence_wrapper.byte_sequence -> string_table

string_table_of_byte_sequence seq constructs a string table, using the NUL * character as terminator, from a byte sequence.

Sourceval empty0 : string_table

empty is the empty string table with an arbitrary choice of delimiter.

Sourceval get_delimiting_character : string_table -> char

get_delimiating_character tbl returns the delimiting character associated * with the string table tbl, used to split the strings.

Sourceval get_base_string : string_table -> string

get_base_string tbl returns the base string of the string table tbl.

Sourceval size0 : string_table -> Nat_big_num.num

size tbl returns the size in bytes of the string table tbl.

concat xs concatenates several string tables into one providing they all * have the same delimiting character.

Sourceval get_string_at : Nat_big_num.num -> string_table -> string Error.error

get_string_at index tbl returns the string starting at character index * from the start of the base string until the first occurrence of the delimiting * character.

Sourceval find_string : string -> string_table -> Nat_big_num.num option
Sourceval insert_string : string -> string_table -> Nat_big_num.num * string_table
Sourceval instance_Show_Show_String_table_string_table_dict : string_table Show.show_class
OCaml

Innovation. Community. Security.