|
pstore2
|
A compilation is a holder for zero or more definitions. More...
#include <compilation.hpp>
Public Types | |
| using | iterator = definition * |
| using | const_iterator = definition const * |
| using | size_type = std::uint32_t |
Public Member Functions | |
| void | operator delete (void *p) |
| typed_address< indirect_string > | triple () const noexcept |
| Returns the target triple. | |
| template<typename TransactionType , typename Iterator > | |
| auto | alloc (TransactionType &transaction, typed_address< indirect_string > triple, Iterator first_member, Iterator last_member) -> extent< compilation > |
Element access | |
| definition const & | operator[] (std::size_t const i) const |
Iterators | |
| iterator | begin () |
| const_iterator | begin () const |
| const_iterator | cbegin () const |
| iterator | end () |
| const_iterator | end () const |
| const_iterator | cend () const |
Capacity | |
| bool | empty () const noexcept |
| Checks whether the container is empty. | |
| size_type | size () const noexcept |
| Returns the number of elements. | |
Static Public Member Functions | |
| static constexpr typed_address< definition > | index_address (typed_address< compilation > const c, size_type const index) noexcept |
Compute the address of the definition given by index within compilation c. More... | |
Construction | |
| template<typename TransactionType , typename Iterator > | |
| static extent< compilation > | alloc (TransactionType &transaction, typed_address< indirect_string > triple, Iterator first_member, Iterator last_member) |
| Allocates a new compilation in-store and copy the ticket file path and the contents of a vector of definitions into it. More... | |
| static std::shared_ptr< compilation const > | load (database const &db, extent< compilation > const &location) |
| Returns a pointer to an in-pstore compilation instance. More... | |
Storage | |
| std::size_t | size_bytes () const noexcept |
| static std::size_t | size_bytes (size_type size) noexcept |
| Returns the number of bytes of storage required for a compilation with 'size' members. More... | |
A compilation is a holder for zero or more definitions.
It is the top-level object representing the result of processing of a transaction unit by the compiler.
|
static |
Allocates a new compilation in-store and copy the ticket file path and the contents of a vector of definitions into it.
| transaction | The transaction to which the compilation will be appended. |
| triple | The target-triple associated with this compilation. |
| first_member | The first of a sequence of definition instances. The range defined by first_member and last_member will be copied into the newly allocated compilation. |
| last_member | The end of the range of definition instances. |
|
inlinestaticnoexcept |
Compute the address of the definition given by index within compilation c.
| c | The address of a compilation. |
| index | The index of a definition within compilation c. |
index within compilation c.
|
static |
Returns a pointer to an in-pstore compilation instance.
| db | The database from which the compilation should be loaded. |
| location | An extent describing the compilation location in the store. |
|
inlinestaticnoexcept |
Returns the number of bytes of storage required for a compilation with 'size' members.
|
inlinenoexcept |
1.8.13