Skip to content

Latest commit

 

History

History
39 lines (32 loc) · 804 Bytes

File metadata and controls

39 lines (32 loc) · 804 Bytes

Definitions

Access

  1. identifier (single)
  2. identifier::::identifier (nested)

Definitions can be accessed via single- or nested-identifiers.

The preceding names in a nested-identifier specify the context of the definition and the last name specifies the name of the accessed definition.

group A {
  group C {
    func test() {
      std::print("called by foo!");
    }
  }
  
  group B {
    group C {
      func test() {
        std::print("called by bar!");
      }
    }
    
    func foo() {
      A::C::test();
    }
    func bar() {
      C::test();
    }
  }
}