# Goga Cell Cpp

> C++ CODEMANIFEST contract implementation rules

- **Type:** Skill
- **Install:** `agentstack add skill-qarium-goga-goga-cell-cpp`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [qarium](https://agentstack.voostack.com/s/qarium)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** BSD-3-Clause
- **Upstream author:** [qarium](https://github.com/qarium)
- **Source:** https://github.com/qarium/goga/tree/1.1.x/goga/assets/skills/goga-cell-cpp

## Install

```sh
agentstack add skill-qarium-goga-goga-cell-cpp
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# C++: Contract Implementation Rules

Language skill for C++.

Apply the specification in the context of the calling skill. Do not retell the content — use it
for decision-making.

Invoked through the `goga-lang-disp` router.

---

## Examples

Full CODEMANIFEST example for C++ with all DSL constructs:

```yaml
Imports:
  - Types:
      - Buffer
      - StreamConfig AS Config
    Usages:
      - memory_layout
    From: path/to/stream_cell

Usages:
  conventions: .goga/usages/cpp_conventions.md
  pattern: |
    Use RAII for resource management. Prefer stack allocation over heap allocation.
  testing: |
    Use Catch2. Each public function must have test coverage.

Annotations: |
  Use `conventions` for code style.
  Use `testing` for test requirements.
  Use `memory_layout` from Imports for buffer alignment rules.

  Use value semantics only. No raw pointers or references in public API.

---

"lookup_entry(std::string key) -> value: int":
  location: engine.hpp
  annotations: |
    Look up an entry by key.

    `key`: lookup key string
    `value`: found value or 0 if not found

    Use `pattern` for implementation.

"Parser(input: std::string)":
  location: parser.hpp
  annotations: |
    Configurable parser for structured input.

    `input`: raw input string

    Use `memory_layout` from Imports for buffer sizing.
    Use `conventions` for code style.
  properties:
    "position -> int": |
      Current parsing position.
    "length -> int": |
      Total input length.
  methods:
    "parse() -> tokens: std::vector": |
      Parse input into tokens.

      `tokens`: parsed token list

      Use `pattern` for implementation.
    "reset()": |
      Reset parser state to beginning.

"Buffer::StreamBuffer(config: Config)":
  location: stream.hpp
  annotations: |
    Stream buffer extending Buffer with configurable capacity.

    `config`: buffer configuration from `Config` type.

    Use `memory_layout` from Imports for allocation strategy.

->Buffer: {}

---

Author: Goga
CreatedAt: 22/05/26
Description: |
  Example CODEMANIFEST demonstrating all DSL constructs for C++.
```

## Cell

A cell is a directory with a public header:

```
cell/
├── CODEMANIFEST
├── cell.hpp
```

## Language Features

**Facade**: the header file (`cell.hpp`) defines the public API. Everything declared in the header within the cell namespace
constitutes the facade. Implementation resides in the corresponding `.cpp` files.

**Naming**: PascalCase for user-defined classes and structs, snake_case for functions and variables.
Standard library types (`std::string`, `std::vector`) are used as-is (snake_case).

**Namespace**: each cell uses its own namespace for isolation.

**Constructors**: the Entity signature describes the class constructor. Constructor parameters are the input data.

**Memory**: pointers, references, and smart pointers are forbidden in the contract. Use value semantics.

## Construct Mapping

| C++                            | CODEMANIFEST     | Note                          |
|--------------------------------|------------------|-------------------------------|
| `class` / `struct` in namespace | Entity           | Constructor → Entity signature |
| Free function in namespace     | Routine          |                               |
| Public member variable         | Property         |                               |
| Public member function         | Method           |                               |
| Constructor                    | Entity signature |                               |

## Implementation

- Public API defined in header
- Use namespace per cell

## Signature Rules

Allowed:
```
std::string
int, double, bool
std::vector
std::map
std::optional
```

Forbidden:
```
pointers (*T)
references (&, &&)
smart pointers
void*
templates in DSL
```

---

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [qarium](https://github.com/qarium)
- **Source:** [qarium/goga](https://github.com/qarium/goga)
- **License:** BSD-3-Clause

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-qarium-goga-goga-cell-cpp
- Seller: https://agentstack.voostack.com/s/qarium
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
