| chigraph master Systems programming language written for beginners in LLVM

Public Member Functions | Public Attributes | List of all members
chi::Result::ScopedContext Struct Reference

A helper object for contexts that should be removed at the end of a scope. More...

`#include <chi/Support/Result.hpp>`

Collaboration diagram for chi::Result::ScopedContext:
[legend]

## Public Member Functions
| ScopedContext (Result &res, int ctxId)
| Create a scoped context object. More...
| ~ScopedContext ()
| Destructor–does the magic of remving itsself from the result.

## Public Attributes
const int | contextId
| The ID for this context.
Result & | result
| The result object.

## Detailed Description

A helper object for contexts that should be removed at the end of a scope.

Definition at line 74 of file Result.hpp.

## Constructor & Destructor Documentation

## ◆ ScopedContext()

chi::Result::ScopedContext::ScopedContext | ( | Result & | res,
|  | int | ctxId
| ) |  |
| inline

Create a scoped context object.

Parameters

  res | The Result to add it to
  ctxId | The ID of this context object

Definition at line 78 of file Result.hpp.

References contextId.

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

- lib/support/include/chi/Support/Result.hpp