double colon after class name (declaration) - what does that mean?

c++

Solution

Or is that an inner class declared out-of-the-main-class?

Bingo. To be super clear, iit's actually an inner class defined outside the enclosing class.

It's a handy trick if you want a class with member-like access to your class as an implementation detail, but do not want to publish that nested class's definition to the clients of your class.

Problem

I've been wondering what does the following mean (code snippet taken from cppreference pimpl) ``` class widget::impl { ^^^^^^^^^^^^ ... }; ``` What does `a_class::another_class` mean? Is that a namespace? Or is that an inner class declared out-of-the-main-class?

Original source

Related problems