CppInterOp
C++ Language Interoperability Layer
Loading...
Searching...
No Matches
Public Attributes | List of all members
CppInterOp::Tracing::OutParam Struct Reference

Marks a function parameter as an output container (e.g. More...

#include "lib/CppInterOp/Tracing.h"

Collaboration diagram for CppInterOp::Tracing::OutParam:
Collaboration graph
[legend]

Public Attributes

std::function< void(TraceInfo &, unsigned OutIdx)> RegisterHandles
 Register the container's pointer elements as handles and emit one void* vN = _outN[i] : nullptr; decl per newly-registered element so a later call referencing the registered name finds a real binding.
 
bool IsPointerContainer = false
 Drives the _outN preamble + alias path.
 
bool IsScalarPointer = false
 Scalar pointer OUT (e.g. bool*); rendered as nullptr.
 
const void * SourceAddr = nullptr
 Address of the source container object (not its data buffer); multiple calls with the same container alias the same _outN buffer in the reproducer so accumulation across calls replays faithfully.
 

Detailed Description

Marks a function parameter as an output container (e.g.

std::vector<T>& that the function fills). Constructed via the INTEROP_OUT(var) macro.

Purpose:

The container type is erased at construction via MakeOutParam() so that all downstream code (ReproBuffer, TraceRegion) works with a single concrete type — no template specializations or detection traits needed.

Definition at line 250 of file Tracing.h.

Member Data Documentation

◆ IsPointerContainer

bool CppInterOp::Tracing::OutParam::IsPointerContainer = false

Drives the _outN preamble + alias path.

Non-pointer containers stay on the legacy "skip in arg list" rendering – their type is not erasable to void*, so the preamble decl would not type-check.

Definition at line 259 of file Tracing.h.

Referenced by CppInterOp::Tracing::MakeOutParam().

◆ IsScalarPointer

bool CppInterOp::Tracing::OutParam::IsScalarPointer = false

Scalar pointer OUT (e.g. bool*); rendered as nullptr.

Definition at line 261 of file Tracing.h.

Referenced by CppInterOp::Tracing::MakeOutParam().

◆ RegisterHandles

std::function<void(TraceInfo&, unsigned OutIdx)> CppInterOp::Tracing::OutParam::RegisterHandles

Register the container's pointer elements as handles and emit one void* vN = _outN[i] : nullptr; decl per newly-registered element so a later call referencing the registered name finds a real binding.

Definition at line 255 of file Tracing.h.

Referenced by CppInterOp::Tracing::MakeOutParam().

◆ SourceAddr

const void* CppInterOp::Tracing::OutParam::SourceAddr = nullptr

Address of the source container object (not its data buffer); multiple calls with the same container alias the same _outN buffer in the reproducer so accumulation across calls replays faithfully.

Stable across capacity growth – a push_back that reallocates the heap buffer leaves the object's address put.

Definition at line 267 of file Tracing.h.

Referenced by CppInterOp::Tracing::MakeOutParam().


The documentation for this struct was generated from the following file: