Home

Michael Heilmann's Arcadia Ring 2

This is the documentation for Michael Heilmann's Arcadia Ring 2. Arcadia Ring 2 facilitates the creation of C programs - in particular interpreters - that are portable, maintainable, as well as safe.

Files

You can find the sources of Arcadia Ring 2 in my GitHub repository https://github.com/michaelheilmann/michaelheilmann.com. The subdirectory of Arcadia Ring 2 in the repository is here https://github.com/michaelheilmann/michaelheilmann.com/tree/main/repository/Ring2.

Arcadia Ring 2 supports various platforms (including but not restricted to Windows, Linux, and many more), however, we currently only officially support Windows. For instructions on how to build, test, and use Arcadia Ring 1, refer to README.md in the root folder of the repository.

Further References

Arcadia Ring 2 relies on Arcadia Ring 1 and Arcadia ARMS.

Documentation

Objects

Arcadia_ByteBuffer

Arcadia_ByteBuffer represents a mutable sequence of Bytes. This type is allocated on the heap and values of this type are referenced by Arcadia_ByteBuffer pointers. A Arcadia_ByteBuffer pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_ByteBuffer value can be safely cast into a Arcadia_ByteBuffer pointer.

Arcadia_ByteBuffer_create

Arcadia_ByteBuffer*
Arcadia_ByteBuffer_create
  (
    Arcadia_Thread* thread
  )
Create a Byte buffer.

Parameters

A pointer to the Arcadia_Thread object.

Errors

Arcadia_Status_AllocationFailed
An allocation failed.

Return value

A pointer to the Byte buffer.

Arcadia_ByteBuffer_clear

void
Arcadia_ByteBuffer_clear
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self
  )
Set the number of elements of this Byte buffer to zero.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.

Arcadia_ByteBuffer_endsWith_pn

Arcadia_BooleanValue
Arcadia_ByteBuffer_endsWith_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer const* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Get if a sequence of Bytes is a suffix of this Byte buffer's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Return value

Arcadia_BooleanValue_True if the sequence of Bytes is a suffix of this byte buffer's sequence of Bytes. Arcadia_BooleanValue_False otherwise.

Arcadia_ByteBuffer_startsWith_pn

Arcadia_BooleanValue
Arcadia_ByteBuffer_startsWith_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Get if a sequence of Bytes is a prefix of this Byte buffer's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Return value

Arcadia_BooleanValue_True if the sequence of Bytes is a prefix of this byte buffer's sequence of Bytes. Arcadia_BooleanValue_False otherwise.

Arcadia_isEqualTo_pn

Arcadia_BooleanValue
Arcadia_ByteBuffer_isEqualTo_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Get if a sequence of Bytes is this Byte buffer's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Return value

Arcadia_BooleanValue_True if the sequence of Bytes is this byte buffer's sequence of Bytes. Arcadia_BooleanValue_False otherwise.

Arcadia_ByteBuffer_append_pn

void
Arcadia_ByteBuffer_append_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Append Bytes to this Byte buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
bytes is a null pointer.
Arcadia_Status_AllocationFailed
An allocation failed.

Arcadia_ByteBuffer_prepend_pn

void
Arcadia_ByteBuffer_prepend_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self,
    void const* p,
    Arcadia_SizeValue n
  )
Prepend Bytes to this Byte buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
void const* p
A pointer to an array of n Bytes.
Arcadia_SizeValue n
The number of Bytes in the array pointed to by p.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
bytes is a null pointer.
Arcadia_Status_AllocationFailed
An allocation failed.

Arcadia_ByteBuffer_insert_pn

void
Arcadia_ByteBuffer_insert_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self,
    Arcadia_SizeValue index,
    void const* p,
    Arcadia_SizeValue n
  )
Insert Bytes into this Byte buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
Arcadia_SizeValue index
The index at which to insert the Bytes. Must be within the bounds of [0,n) where n is the size of this Byte buffer.
void const* p
A pointer to an array of n Bytes.
Arcadia_SizeValue n
The number of Bytes in the array pointed to by p.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
bytes is a null pointer.
Arcadia_Status_AllocationFailed
An allocation failed.

Arcadia_ByteBuffer_isEqualTo

Arcadia_BooleanValue
Arcadia_ByteBuffer_isEqualTo
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer const* self,
    Arcadia_ByteBuffer const* other
  )
Compare this Byte buffer with another Byte buffer for equality.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer const* self
A pointer to this Byte buffer.
Arcadia_ByteBuffer const* other
A pointer to the other Byte buffer.

Return value

Arcadia_BooleanValue_True if this Byte buffer is equal to the other Byte buffer. Arcadia_BooleanValue_False otherwise.

Arcadia_ByteBuffer_getSize

Arcadia_SizeValue
Arcadia_ByteBuffer_getSize
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer const* self
  )
Get the size of this Byte buffer. Remarks: The size of a Byte buffer is the length of the Byte sequence it contains.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.

Return value

The size of this Byte buffer.

Arcadia_ByteBuffer_getAt

Arcadia_Natural8Value
Arcadia_ByteBuffer_getAt
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer const* self,
    Arcadia_SizeValue index
  )
Get the Byte value at the specified index. Remarks: The size of a Byte buffer is the length of the Byte sequence it contains.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
Arcadia_SizeValue index
The index. Must be within the bounds [0,n) where n is the size of this Byte buffer.

Return value

The Byte value.

Arcadia_ByteBuffer_isEmpty

Arcadia_BooleanValue
Arcadia_ByteBuffer_isEmpty
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self
  )
Get if this Byte buffer is empty.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.

Return value

Arcadia_BooleanValue_True if this Byte buffer is empty. Arcadia_BooleanValue_False otherwise.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.

Arcadia_ByteBuffer_swap

void
Arcadia_ByteBuffer_swap
  (
    Arcadia_Thread* thread,
    Arcadia_ByteBuffer* self,
    Arcadia_ByteBuffer* other
  )
Swap the contents of this Byte buffer with the contents of another Byte buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_ByteBuffer* self
A pointer to this Byte buffer.
Arcadia_ByteBuffer* self
A pointer to the other Byte buffer.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
other is a null pointer.

Arcadia_FileHandle

Arcadia_FileHandle represents a operating system file handle. This type is allocated on the heap and values of this type are referenced by Arcadia_FileHandle pointers. A Arcadia_FileHandle pointer can be safely cast into a R_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_FileHandle value can be safely cast into a Arcadia_FileHandle pointer.

Arcadia_FileHandle_create

Arcadia_FileHandle*
Arcadia_FileHandle_create
  (
    Arcadia_Thread* thread,
    Arcadia_FileSystem* fileSystem
  )
Create a file handle. The file handle is closed.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_FileSystem* self
A pointer to the backing Arcadia_FileSystem object.

Return value

A pointer to the file handle.

Arcadia_FileHandle_close

void
Arcadia_FileHandle_close
  (
    Arcadia_Thread* thread,
    Arcadia_FileHandle* self
  )
Close this file handle.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_FileHandle* self
A pointer to this file handle.

Arcadia_FileHandle_openForReading

void
Arcadia_FileHandle_openForReading
  (
    Arcadia_Thread* thread,
    Arcadia_FileHandle* self,
    Arcadia_FilePath* path
  )
Open a file for reading. If the file is open, it is closed before trying to re-open it.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_FileHandle* self
A pointer to this file handle.
Arcadia_FilePath* path
The file path of the file to read from.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
path is a null pointer.
Arcadia_Status_FileSystemOperationFailed
Opening the file failed.

Arcadia_FileHandle_openForWriting

void
Arcadia_FileHandle_openForWriting
  (
    Arcadia_FileHandle* self,
    Arcadia_FilePath* path
  )
Open a file for writing. If the file is open, it is closed before trying to re-open it.

Parameters

Arcadia_FileHandle* self
A pointer to this file handle.
Arcadia_FilePath* path
The file path of the file to write to.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
path is a null pointer.
Arcadia_Status_FileSystemOperationFailed
Opening the file failed.

Arcadia_FileHandle_isClosed

Arcadia_BooleanValue
Arcadia_FileHandle_isClosed
  (
    Arcadia_FileHandle const* self
  )
Get if this file handle is closed.

Parameters

Arcadia_FileHandle const* self
A pointer to this file handle.

Return value

Arcadia_BooleanValue_True if this file handle is closed. Arcadia_BooleanValue_False otherwise.

Arcadia_FileHandle_isOpened

Arcadia_BooleanValue
Arcadia_FileHandle_isOpened
  (
    Arcadia_FileHandle const* self
  )
Get if this file handle is opened.

Parameters

Arcadia_FileHandle const* self
A pointer to this file handle.

Return value

Arcadia_BooleanValue_True if this file handle is opened. Arcadia_BooleanValue_False otherwise.

Arcadia_FileHandle_isOpenedForReading

Arcadia_BooleanValue
Arcadia_FileHandle_isOpenedForReading
  (
    Arcadia_FileHandle const* self
  )
Get if this file handle is opened for reading.

Parameters

Arcadia_FileHandle const* self
A pointer to this file handle.

Return value

Arcadia_BooleanValue_True if this file handle is opened for reading. Arcadia_BooleanValue_False otherwise.

Arcadia_FileHandle_isOpenedForWriting

Arcadia_BooleanValue
Arcadia_FileHandle_isOpenedForWriting
  (
    Arcadia_FileHandle const* self
  )
Get if this file handle is opened for writing.

Parameters

Arcadia_FileHandle const* self
A pointer to this file handle.

Return value

Arcadia_BooleanValue_True if this file handle is opened for writing. Arcadia_BooleanValue_False otherwise.

Arcadia_FileHandle_write

void
Arcadia_FileHandle_write
  (
    Arcadia_FileHandle* self,
    void const* p,
    Arcadia_SizeValue bytesToWrite
  )
Write Bytes to this file handle.

Parameters

Arcadia_FileHandle* self
A pointer to this file handle.
void const* bytes
A pointer to an array of bytesToWrite Bytes.
Arcadia_SizeValue bytesToWrite
The number of Bytes in the array pointed to by bytes.
Arcadia_SizeValue* bytesWritten
A pointer to a Arcadia_SizeValue variable.

Success

*bytesWritten is assigned the actual number of Bytes written.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
bytes is a null pointer.
Arcadia_Status_OperationInvalid
The file is not opened for writing.
Arcadia_Status_FileSystemOperationFailed
Writing failed.

Arcadia_FileHandle_read

void
Arcadia_FileHandle_read
  (
  Arcadia_FileHandle* self,
  void const* bytes,
  Arcadia_SizeValue bytesToRead,
  Arcadia_SizeValue* bytesRead
  )
Read Bytes from this file handle.

Parameters

Arcadia_FileHandle* self
A pointer to this file handle.
void const* bytes
A pointer to an array of bytesToWrite Bytes.
Arcadia_SizeValue bytesToRead
The number of Bytes to read from the the array pointed to by bytes.
Arcadia_SizeValue* bytesRead
A pointer to a Arcadia_SizeValue variable.

Success

*bytesRead is assigned the actual number of Bytes read. The number of Bytes read is 0 if the end of the file was reached.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
bytes is a null pointer.
Arcadia
bytesRead is a null pointer.
Arcadia_Status_OperationInvalid
The file is not opened for writing.
Arcadia_Status_FileSystemOperationFailed
Writing failed.

Arcadia_FilePath

Arcadia_FilePath represents a file path. This type is allocated on the heap and values of this type are referenced by Arcadia_FilePath pointers. A Arcadia_FilePath pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_FilePath value can be safely cast into a Arcadia_FilePath pointer.

create

Arcadia_FilePath*
Arcadia_FilePath_create
  (
    Arcadia_Thread* thread
  )
Create the empty file path.

Parameters

A pointer to the Arcadia_Thread object.

Return value

A pointer to the file path.

Arcadia_FilePath_parseWindows

Arcadia_FilePath*
Arcadia_FilePath_parseWindows
  (
    Arcadia_Thread* thread,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Parse a file path in the Windows format.

Parameters

A pointer to the Arcadia_Thread object.
bytes
A pointer to an array of numberOfBytes Bytes.
numberOfBytes
The number of Bytes in the array pointed to by bytes Bytes.

Return value

A pointer to the file path.

Arcadi_FilePath_parseUnix

Arcadia_FilePath*
Arcadia_FilePath_parseUnix
  (
    Arcadia_Thread* thread,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Parse a file path in the Unix format.

Parameters

A pointer to the Arcadia_Thread object.
bytes
A pointer to an array of numberOfBytes Bytes.
numberOfBytes
The number of Bytes in the array pointed to by bytes Bytes.

Return value

A pointer to the file path.

Arcadia_FilePath_parseNative

Arcadia_FilePath*
Arcadia_FilePath_parseNative
  (
    Arcadia_Thread* thread,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Parse a file path in the native format.

Parameters

A pointer to the Arcadia_Thread object.
bytes
A pointer to an array of numberOfBytes Bytes.
numberOfBytes
The number of Bytes in the array pointed to by bytes Bytes.

Return value

A pointer to the file path.

Arcadia_FilePath_toNative

Arcadia_String*
Arcadia_FilePath_toNative
  (
    Arcadia_Thread* thread,
    Arcadia_FilePath* self
  )
Convert a file path to the native format.

Parameters

A pointer to the Arcadia_Thread object.
self
A pointer to this file path.

Return value

A pointer to the string.

Arcadia_FileSystem

Arcadia_FileSystem provides access to the file system. This type is allocated on the heap and values of this type are referenced by Arcadia_FileSystem pointers. A Arcadia_FileSystem pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_FileSystem value can be safely cast into a Arcadia_FileSystem pointer.

Arcadia_FileSystem_create

Arcadia_FileSystem*
Arcadia_FileSystem_create
  (
    Arcadia_Thread* thread
  )
Create a file system.

Parameters

A pointer to the Arcadia_Thread object.

Errors

Arcadia_Status_AllocationFailed
An allocation failed.

Arcadia_FileSystem_getFileContents

Arcadia_ByteBuffer*
Arcadia_FileSystem_getFileContents
  (
    Arcadia_Thread* thread,
    Arcadia_FileSystem* self,
    Arcadia_FilePath* path
  )
Get the contents of a file.

Parameters

A pointer to the Arcadia_Process object.
A pointer to this Arcadia_FileSystem object.
The file path of the file.

Return value

A pointer to a Arcadia_ByteBuffer object with the file contents.

Errors

self is a null pointer.
path is a null pointer.
Opening the file failed.

Arcadia_FileSystem_setFileContents

void
Arcadia_FileSystem_setFileContents
  (
    Arcadia_Thread* thread,
    Arcadia_FileSystem* self,
    Arcadia_FilePath* path,
    Arcadia_ByteBuffer* contents
  )
Get if a sequence of Bytes is a prefix of this string's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
A pointer to this Arcadia_FileSystem object.
Arcadia_FilePath* path
The file path of the file.
Arcadia_ByteBuffer* contents
A poiner to the Byte buffer with the file contents.

Errors

Arcadia_Status_ArgumentValueInvalid
sekf is a null pointer.
Arcadia_Status_ArgumentValueInvalid
path is a null pointer.
Arcadia_Status_ArgumentValueInvalid
contents is a null pointer.
Arcadia_Status_FileSystemOperationFailed
Opening the file failed.

Arcadia_FileSystem_regularFileExists

Arcadia_BooleanValue
Arcadia_FileSystem_regularFileExists
  (     Arcadia_Thread* thread,
    Arcadia_FileSystem* self,
    Arcadia_FilePath* path
  )
Get if a file exists and is a regular file.

Parameters

A pointer to the Arcadia_Thread object.
A pointer to this Arcadia_FileSystem object.
Arcadia_FilePath* path
The file path of the file.

Return value

Arcadia_BooleanValue_True if the file exists and is a regular file. Arcadia_BooleanValue_False otherwise.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalidpath is a null pointer.

Arcadia_FileSystem_directoryFileExists

Arcadia_BooleanValue
Arcadia_FileSystem_directoryFileExists
  (
    Arcadia_Thread* thread,
    Arcadia_FileSystem* self,
    Arcadia_FilePath* path
  )
Get if a file exists and is a directory file.

Parameters

A pointer to the Arcadia_Thread object.
A pointer to this Arcadia_FileSystem object.
Arcadia_FilePath* path
The file path of the file.

Return value

Arcadia_BooleanValue_True if the file exists and is a directory file. Arcadia_BooleanValue_False otherwise.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
path is a null pointer.

Arcadia_List

Arcadia_List represents a list of Arcadia_Value objects. This type is allocated on the heap and values of this type are referenced by Arcadia_List pointers. A Arcadia_List pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_List value can be safely cast into a Arcadia_List pointer.

Arcadia_List_clear

void
Arcadia_List_clear
  (
    Arcadia_Thread* thread,
    Arcadia_List* self
  )
Clear this list.

Parameters

A pointer to the Arcadia_Process object.
Arcadia_List* self
A pointer to this list.

Arcadia_List_create

Arcadia_List*
Arcadia_List_create
  (
    Arcadia_Thread* thread
  )
Create a list.

Parameters

A pointer to the Arcadia_Process object.

Errors

Arcadia_Status_AllocationFailed
An allocation failed.

Return value

A pointer to the Arcadia_List value.

Arcadia_List_getAt

Arcadia_Value
Arcadia_List_getAt
  (
    Arcadia_Thread* thread,
    Arcadia_List* self,
    Arcadia_SizeValue index
  )
Get the value at the specifie index in this list.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_List* self
A pointer to this list.
Arcadia_SizeValue index
The index. Must be within the bounds [0,n) where n is the size of this list.

Errors

Arcadia_Status_ArgumentValueInvalid
index is out of bounds.

Return value

The value.

Arcadia_List_getSize

Arcadia_SizeValue
Arcadia_List_getSize
  (
    Arcadia_Thread* thread,
    Arcadia_List const* self
  )
Get the size of this list.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_List* self
A pointer to this list.

Return value

The size of this list.

Arcadia_List_insertAt

void
Arcadia_List_insertAt
  (
    Arcadia_Thread* thread,
    Arcadia_List* self,
    Arcadia_SizeValue index,
    Arcadia_Value value
  )
Insert a value at the specified position in this list.

Parameters

Arcadia_Thread* threadA pointer to the Arcadia_Thread object. Arcadia_List* self A pointer to this list. Arcadia_SizeValue index The index at which to insert the value. Must be within the bounds of [0,n] where n is the size of thie list. Arcadia_Value value The value to insert.

Errors

Arcadia_Status_ArgumentValueInvalid
index is out of bounds.

Arcadia_List_insertBack

void
Arcadia_List_insertBack
  (
    Arcadia_Thread* thread,
    Arcadia_List* self,
    Arcadia_Value value
  )
Insert a valu at the back of this list.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_List* self
A pointer to this list.
Arcadia_Value value
The value to insert at the back of this list.

Arcadia_List_insertFront

void
Arcadia_List_insertFront
  (
    Arcadia_Thread* thread,
    Arcadia_List* self,
    Arcadia_Value value
  )
Insert a value at the front of this list.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_List* self
A pointer to this list.
Arcadia_Value value
The value to insert at the front of this list.

Arcadia_List_isEmpty

Arcadia_BooleanValue
Arcadia_List_isEmpty
  (
    Arcadia_Thread* thread,
    Arcadia_List* self
  )
Get if this list is empty.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_List* self
A pointer to this list.

Return value

Arcadia_BooleanValue_True if this list is empty. Arcadia_BooleanValue_False otherwise.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.

Arcadia_List_removeAt

void
Arcadia_List_removeAt   (
    Arcadia_Thread* thread,
    Arcadia_List* self,
    Arcadia_SizeValue start,
    Arcadia_SizeValue length
  )
Remove length values starting with element at index start.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_List* self
A pointer to this list.
Arcadia_SizeValue start
The index of the first element to remove.
Arcadia_SizeValue length
The number of elements to remove.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.
Arcadia_Status_ArgumentValueInvalid
index + length > n where n is the length of the list.

Stack

Arcadia_Stack represents a stack of Arcadia_Value objects. This type is allocated on the heap and values of this type are referenced by Arcadia_Stack pointers. A Arcadia_Stack pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_Stack value can be safely cast into a Arcadia_Stack pointer.

Arcadia_Stack_clear

void
Arcadia_Stack_clear
  (
    Arcadia_Thread* thread,
    Arcadia_Stack* self
  )
Clear this stack.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Stack* self
A pointer to this stack.

Arcadia_Stack_create

Arcadia_Stack*
Arcadia_Stack_create
  (
    Arcadia_Thread* thread
  )
Create a stack.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.

Errors

Arcadia_Status_ArgumentValueInvalid
bytes is a null pointer.
Arcadia_Status_EncodingInvalid
The sequence of Bytes does not represented a UTF-8-NO-BOM string.

Return value

A pointer to the Arcadia_Stack value.

Arcadia_Stack_getSize

Arcadia_SizeValue
Arcadia_Stack_getSize
  (
    Arcadia_Thread* thread,
    Arcadia_Stack const* self
  )
Get the size of this stack.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Stack* self
A pointer to this stack.

Return value

The size of this stack.

Arcadia_Stack_isEmpty

Arcadia_BooleanValue
Arcadia_Stack_isEmpty
  (
    Arcadia_Thread* thread,
    Arcadia_Stack* self
  )
Get if this stack is empty.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Stack* self
A pointer to this stack.

Return value

Arcadia_BooleanValue_True if this stack is empty. Arcadia_BooleanValue_False otherwise.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.

Arcadia_Stack_peek

Arcadia_Value
Arcadia_Stack_peek
  (
    Arcadia_Thread* thread,
    Arcadia_Stack* self
  )
Peek at the value on top of this stack.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Stack* self
A pointer to this stack.

Return value

The value.

Arcadia_Stack_pop

Arcadia_Value
Arcadia_Stack_pop   (
    Arcadia_Thread* thread,
    Arcadia_Stack* self
  )
Pop the value from the top of this stack.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Stack* self
A pointer to this stack.

Return value

The value.

Arcadia_Stack_push

void
Arcadia_Stack_push
  (
    Arcadia_Thread* thread,
    Arcadia_Stack* self,
    Arcadia_Value value
  )
Push a value on the top of this stack.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Stack* self
A pointer to this stack.
Arcadia_Value value
The value to push.

Arcadia_StringBuffer

Arcadia_StringBuffer represents a mutable UTF-8 Byte sequence. This type is allocated on the heap and values of this type are referenced by Arcadia_StringBuffer pointers. A Arcadia_StringBuffer pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_StringBuffer value can be safely cast into a Arcadia_StringBuffer pointer.

Arcadia_StringBuffer_clear

void
Arcadia_StringBuffer_clear
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer* self
  )
Clear this string buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer self
A pointer to this string buffer.

Arcadia_StringBuffer_create

Arcadia_StringBuffer*
Arcadia_StringBuffer_create
  (
    Arcadia_Thread* thread
  )
Create a string buffer.

Parameters

A pointer to the Arcadia_Thread object.

Errors

Arcadia_Status_AllocationFailed
An allocation failed.

Return value

A pointer to the Arcadia_StringBuffer value.

Arcadia_StringBuffer_compareTo

Arcadia_Integer32Value*
Arcadia_StringBuffer_compareTo
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer* self,
    Arcadia_Value other
  )
Compare the string in this string buffer with another string lexicographically.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer* self
A pointer to this string buffer.
Arcadia_Value other
The value to compare the UTF-8 string in this string buffer to. The value must be one of Arcadia.ImmutableUtf8String, Arcadia.StringBuffer, or Arcadia.String.

Errors

Arcadia_Status_AllocationFailed
An allocation failed.

Return value

  • A negative value is returned if the string in this string buffer is lexicographically less than the other string.
  • A positive value is returned if the string in this string buffer is lexicographically greater than the other string.
  • If both strings are lexicographically equal, then zero is returned.

Remarks

Let a and b be UTF-8 strings of n and m Bytes, respectively. Denote the i-th Byte of a by a[i] (given a is not empty) and the i-th Byte of b by b[i] (given that b is not empty), respectively. Then comparing a and b lexicographically means: Let l := min(n,m). If l is 0 or a[i] = b[i] for all i in [0, l-1], then

  • a is lexicographically less than b if n < m
  • a is lexicographically greater than b if n > m
  • a and b are lexicographically equal if n = m

Otherwise there exists an i in [0, l - 1] such that for all a[j] = b[j] for all j < i holds and a[i] != b[i]. In that case:

  • a is lexicographically less than b if a[i] < b[i]
  • a is lexicographically greater than b if a[i] > b[i]

Arcadia_StringBuffer_getNumberOfBytes

Arcadia_SizeValue
Arcadia_StringBuffer_getNumberOfBytes
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer self
  )
Get the number of Bytes in this string buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer* self
A pointer to this string buffer.

Return value

The number of Bytes in this string buffer.

Arcadia_StringBuffer_insertAt

void
Arcadia_StringBuffer_insertAt
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer* self,
    Arcadia_SizeValue index,
    Arcadia_Value value
  )
Insert a value at a code point index of string buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer* self
A pointer to this string buffer.
Arcadia_SizeValue index
The code point index at which to insert the value. Must be within the bounds of [0,n] where n is the number of code points in this string buffer. If index is 0, then this call is equivalent to a call to Arcadia_StringBuffer_insertFront. If index is n, then this call is equivalent to a call to Arcadia_StringBuffer_insertBack.
Arcadia_Value value
The value to insert at the code point index. The value must be of one of the following types: Arcadia.ImmutableByteArray, Arcadia.ImmutableUtf8String, Arcadia.ByteBuffer, Arcadia.StringBuffer, or Arcadia.String.

Errors

Arcadia_Status_ArgumentTypeInvalid
value is not of an accepted type.
Arcadia_Status_ArgumentValueInvalid
index is not within the bounds of [0,n] where n is the number of code points in this string buffer.
Arcadia_Status_EncodingInvalid
value is of type Arcadia.ImmutableByteArray or Arcadia.ByteBuffer and the Bytes are not a valid UTF-8 Byte sequence.

Arcadia_StringBuffer_insertBack

void
Arcadia_StringBuffer_insertFront
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer* self,
    Arcadia_Value value
  )
Insert a value at the back of this string buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer* self
A pointer to this string buffer.
Arcadia_Value value
The value to insert at the back. The value must be of one of the following types: Arcadia.ImmutableByteArray, Arcadia.ImmutableUtf8String, Arcadia.ByteBuffer, Arcadia.StringBuffer, or Arcadia.String.

Errors

Arcadia_Status_ArgumentTypeInvalid
value is not of an accepted type.
Arcadia_Status_EncodingInvalid
value is of type Arcadia.ImmutableByteArray or Arcadia.ByteBuffer and the Bytes are not a valid UTF-8 Byte sequence.

Arcadia_StringBuffer_insertFront

void
Arcadia_StringBuffer_insertFront
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer* self,
    Arcadia_Value value
  )
Insert a value at the front of this string buffer.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer* self
A pointer to this string buffer.
Arcadia_Value value
The value to insert at the front. The value must be of one of the following types: Arcadia.ImmutableByteArray, Arcadia.ImmutableUtf8String, Arcadia.ByteBuffer, Arcadia.StringBuffer, or Arcadia.String.

Errors

Arcadia_Status_ArgumentTypeInvalid
value is not of an accepted type.
Arcadia_Status_EncodingInvalid
value is of type Arcadia.ImmutableByteArray or Arcadia.ByteBuffer and the Bytes are not a valid UTF-8 Byte sequence.

Arcadia_StringBuffer_isEmpty

Arcadia_BooleanValue
Arcadia_StringBuffer_isEmpty
  (
    Arcadia_Thread* thread,
    Arcadia_StringBuffer* self
  )
Get if this string buffer is empty.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_StringBuffer* self
A pointer to this string buffer.

Return value

Arcadia_BooleanValue_True if this string buffer is empty. Arcadia_BooleanValue_False otherwise.

Errors

Arcadia_Status_ArgumentValueInvalid
self is a null pointer.

Arcadia_String

Arcadia_String represents an Unicode string encoded as UTF-8-NO-BOM. This type is allocated on the heap and values of this type are referenced by Arcadia_String pointers. A Arcadia_String pointer can be safely cast into a Arcadia_ObjectReferenceValue values. An Arcadia_ObjectReferenceValue pointing to a Arcadia_String value can be safely cast into a Arcadia_String pointer.

Arcadia_String derives fro Arcadia_Object and overrides the following methods:

  • Arcadia_Object_equalTo
  • Arcadia_Object_hash
  • Arcadia_Object_notEqualTo

Arcadia_String_create_pn

Arcadia_String*
Arcadia_String_create_pn
  (
    Arcadia_Thread* thread,
    Arcadia_ImmutableByteArray* immutableByteArray
  )
Create a string from an immutable Byte array.

Parameters

Arcadia_Thread* threadA pointer to the Arcadia_Thread object. Arcadia_ImmutableByteBuffer* immutableByteArrayA pointer to the Arcadia_ImmutableByteArray object

Return value

A pointer to the Arcadia_String object.

Errors

Arcadia_Status_ArgumentValueInvalidimmutableByteArray is a null pointer. Arcadia_Status_EncodingInvalid The sequence of Bytes does not represented a UTF-8-NO-BOM string.

Arcadia_String_create

Arcadia_String*
Arcadia_String_create
  (
    Arcadia_Thread* thread,
    Arcadia_Value value
  )

Create a string from a value.

The following values are accepted:

The specified value may contain a Arcadia_ByteBuffer object. In that case, the string is created from the Bytes of the Byte buffer object. A Arcadia_Status_EncodingInvalid is raised if the Byte sequence of that Arcada_ByteBuffer object is not a UTF8 Byte sequence.

The specified value may contain a Arcadia_ImmutableByteArray object. In that case, the string is created from the Arcadia_ImmutableByteArray object. A Arcadia_Status_EncodingInvalid is raised if the Byte sequence of that Arcada_ImmutableByteArray object is not a UTF8 Byte sequence.

The specified value may contain a Arcadia_String object. In that case, the string is created from the Arcadia_String object.

The specified value may contain a Arcadia_StringBuffer object. In that case, the string is created from the Arcadia_StringBuffer object.

The specified value may contain a Arcadia_ImmutableUtf8String object. In that case, the string is created from the Arcadia_ImmutableUtf8String object.

Parameters

Arcadia_Thread* thread
A pointer to the Arcadia_Thread object.
Arcadia_Value value
The value.

Return value

A pointer to the string.

Errors

Arcadia_Status_ArgumentTypeInvalid
The value is not of type Arcadia_ByteBuffer, Arcadia_String, Arcadia_StringBuffer, or Arcadia_ImmutableByteArray.
Arcadia_Status_EncodingInvalid
The value is a Arcadia_ByteBuffer or Arcadia_ImmutableByteArray. However, the Byte sequence of that Arcadia_ByteBuffer or Arcadia_ImmutableByteArray object is not a UTF8 Byte sequence.

Arcadia_String_endsWith_pn

Arcadia_BooleanValue
Arcadia_String_endsWith_pn
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Get if a sequence of Bytes is a suffix of this string's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Return value

Arcadia_BooleanValue_True if the sequence of Bytes is a suffix of this string's sequence of Bytes. Arcadia_BooleanValue_False otherwise.

Arcadia_String_startsWith_pn

Arcadia_BooleanValue
Arcadia_String_startsWith_pn
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Get if a sequence of Bytes is a prefix of this string's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Return value

Arcadia_BooleanValue_True if the sequence of Bytes is a prefix of this string's sequence of Bytes. Arcadia_BooleanValue_False otherwise.

Arcadia_String_isEqualTo_pn

Arcadia_BooleanValue
Arcadia_String_isEqualTo_pn
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self,
    void const* bytes,
    Arcadia_SizeValue numberOfBytes
  )
Get if a sequence of Bytes is this string's sequence of Bytes.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.
void const* bytes
A pointer to an array of n Bytes.
Arcadia_SizeValue numberOfBytes
The number of Bytes in the array pointed to by p.

Return value

Arcadia_BooleanValue_True if the sequence of Bytes is this string's sequence of Bytes. Arcadia_BooleanValue_False otherwise.

Arcadia_String_getNumberOfBytes

Arcadia_SizeValue
Arcadia_String_getNumberOfBytes
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Get the size, in Bytes, of this string.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The size, in Bytes, of this string.

Arcadia_String_getByteAt

Arcadia_Natural8Value
Arcadia_String_getByteAt
  (
    Arcadia_String const* self,
    Arcadia_SizeValue index
  )
Get the Byte value at the specified index.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.
Arcadia_SizeValue index
The index. Must be within the bounds [0,n) where n is the size, in Bytes, of this string.

Return value

The Byte value.

Arcadia_String_toBoolean

Arcadia_BooleanValue
Arcadia_String_toBoolean
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as boolean literal and convert the boolean represented by that literal into an Arcadia_BooleanValue.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The boolean value.

Errors

Arcadia_Status_ArgumentTypeInvalid self is a null pointer. Arcadia_Status_ConversionFailed The symbols of this string cannot be interpreted as a boolean literal. Valid boolean literals are true and false, both case sensitve.

Arcadia_String_toInteger16

Arcadia_Integer16Value
Arcadia_String_toInteger16
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as decimal integer literal and convert the number represented by that integer literal into an Arcadia_Integer16Value.

Parameters

Arcadia_Thread* threadA pointer to the Arcadia_Thread object. Arcadia_String* selfA pointer to this string.

Return value

The integer value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal integer literal or the number represented by the literal cannot be represented a value of type Arcadia_Integer16Value.

Arcadia_String_toInteger32

Arcadia_Integer32Value
Arcadia_String_toInteger32
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as decimal integer literal and convert the number represented by that literal into an Arcadia_Integer32Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The integer value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal integer literal or the number represented by the literal cannot be represented a value of type Arcadia_Integer32Value.

Arcadia_String_toInteger64

Arcadia_Integer64Value
Arcadia_String_toInteger64
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as decimal integer literal and convert the number represented by that literal into an Arcadia_Integer64Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The integer value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal integer literal or the number represented by the literal cannot be represented a value of type Arcadia_Integer64Value.

Arcadia_String_toInteger8

Arcadia_Integer8Value
Arcadia_String_toInteger8
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as decimal integer literal and convert the number represented by that literal into an Arcadia_Integer8Value.

Parameters

Arcadia_Thread* threadA pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The integer value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal integer literal or the number represented by the integer literal cannot be represented a value of type Arcadia_Integer8Value.

Arcadia_String_toNatural16

Arcadia_Natural16Value
Arcadia_Stringg_toNatural16
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as decimal natural literal and convert the number represented by that literal into an Arcadia_Natural16Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The natural value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal natural literal or the number represented by the literal cannot be represented a value of type Arcadia_Natural16Value.

Arcadia_String_toNatural32

Arcadia_Natural32Value
Arcadia_String_toNatural32
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as decimal natural literal and convert the number represented by that literal into an Arcadia_Natural32Value.

Parameters

Arcadia_Thread* threadA pointer to the Arcadia_Thread object. Arcadia_String* selfA pointer to this string.

Return value

The natural value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal natural literal or the number represented by the literal cannot be represented a value of type Arcadia_Natural32Value.

Arcadia_String_toNatural64

Arcadia_Natural64Value
Arcadia_String_toNatural64
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as a decimal natural literal and convert the number represented by that literal into an Arcadia_Natural64Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The natural value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal natural literal or the number represented by the literal cannot be represented a value of type Arcadia_Natural64Value.

Arcadia_String_toNatural8

Arcadia_Natural8Value
Arcadia_String_toNatural8
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as a decimal natural literal and convert the number represented by that literal into an Arcadia_Natural8Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The natural value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal natural literal or the number represented by the literal cannot be represented a value of type Arcadia_Natural8Value.

Arcadia_String_toReal32

Arcadia_Real32Value
Arcadia_String_toReal32
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as a decimal real literal and convert the number represented by that literal into an Arcadia_Real32Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The Arcadia_Real32Value value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal real literal or the number represented by the literal cannot be represented a value of type Arcadia_Real32Value.

Arcadia_String_toReal64

Arcadia_Real64Value
Arcadia_String_toReal64
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as a decimal real literal and convert the number represented by that literal into an Arcadia_Real64Value.

Parameters

A pointer to the Arcadia_Thread object.
Arcadia_String* self
A pointer to this string.

Return value

The Arcadia_Real64Value value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a decimal real literal or the number represented by the literal cannot be represented a value of type Arcadia_Real64Value.

Arcadia_String_toVoid

Arcadia_VoidValue
Arcadia_String_toVoid
  (
    Arcadia_Thread* thread,
    Arcadia_String const* self
  )
Interprete the symbols of this string as a void literal and convert the void value represented by that literal into an Arcadia_VoidValue.

Parameters

Arcadia_Thread* threadA pointer to the Arcadia_Thread object. Arcadia_String* selfA pointer to this string.

Return value

The void value.

Errors

Arcadia_Status_ArgumentTypeInvalid
self is a null pointer.
Arcadia_Status_ConversionFailed
The symbols of this string cannot be interpreted as a void literal. The valid void literal is void, case sensitve.