# std::experimental::any::clear

> C++ Atlas: `cppatlas.com/w/cpp/experimental/any/clear` | Source: https://en.cppreference.com/w/cpp/experimental/any/clear | Domain: Technical specifications

If not empty, destroys the contained object.

## Official Specification Summary (cppreference)

```cpp
void clear() noexcept; // (library fundamentals TS)
```

If not empty, destroys the contained object.

### Parameters

(none)

### Return value

(none)

---
Attribution: content from https://en.cppreference.com/w/cpp/experimental/any/clear (cppreference.com), licensed under CC-BY-SA 3.0 and GFDL. Modified: converted to markdown, study notes added. Offline snapshot of 9 February 2025.