# mod.ts
export namespace Namespace1 {
  export function test() {
  }
}
export namespace Namespace1.Inner {
  export function test2() {
  }
}

import test = Namespace1.test;
import test2 = Namespace1.Inner.test2;

export { test, test2 };

# output
file:///mod.ts: EsModuleInfo {
    module_id: ModuleId(
        0,
    ),
    specifier: "file:///mod.ts",
    re_exports: [],
    swc_id_to_symbol_id: {
        (
            "Namespace1",
            #2,
        ): 1,
        (
            "test",
            #3,
        ): 2,
        (
            "Inner",
            #5,
        ): 3,
        (
            "test2",
            #5,
        ): 4,
        (
            "test",
            #2,
        ): 5,
        (
            "test2",
            #2,
        ): 6,
    },
    symbols: {
        0: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 0,
            parent_id: None,
            decls: [
                SymbolDecl {
                    kind: Definition(
                        SymbolNode(
                            "export namespace Namespace1 {\n  export function test() {\n  }\n}\nexport namespace Namespace1.Inner {\n  export function test2() {\n  }\n}\n\nimport test = Namespace1.test;\nimport test2 = Namespace1.Inner.test2;\n\nexport { test, test2 };",
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            0,
                        ),
                        end: SourcePos(
                            228,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {
                1,
            },
            exports: {
                "Namespace1": 1,
                "test": 7,
                "test2": 8,
            },
            members: {},
        },
        1: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 1,
            parent_id: Some(
                0,
            ),
            decls: [
                SymbolDecl {
                    kind: Definition(
                        SymbolNode(
                            "export namespace Namespace1 {\n  export function test() {\n  }\n}",
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            0,
                        ),
                        end: SourcePos(
                            62,
                        ),
                    },
                    flags: 0,
                },
                SymbolDecl {
                    kind: Definition(
                        SymbolNode(
                            "export namespace Namespace1.Inner {\n  export function test2() {\n  }\n}",
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            63,
                        ),
                        end: SourcePos(
                            132,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {
                2,
                3,
            },
            exports: {
                "test": 2,
                "Inner": 3,
            },
            members: {},
        },
        2: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 2,
            parent_id: Some(
                1,
            ),
            decls: [
                SymbolDecl {
                    kind: Definition(
                        SymbolNode(
                            "export function test() {\n  }",
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            32,
                        ),
                        end: SourcePos(
                            60,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {},
            exports: {},
            members: {},
        },
        3: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 3,
            parent_id: Some(
                1,
            ),
            decls: [
                SymbolDecl {
                    kind: Definition(
                        SymbolNode(
                            "namespace Namespace1.Inner {\n  export function test2() {\n  }\n}",
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            91,
                        ),
                        end: SourcePos(
                            132,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {
                4,
            },
            exports: {
                "test2": 4,
            },
            members: {},
        },
        4: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 4,
            parent_id: Some(
                3,
            ),
            decls: [
                SymbolDecl {
                    kind: Definition(
                        SymbolNode(
                            "export function test2() {\n  }",
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            101,
                        ),
                        end: SourcePos(
                            130,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {},
            exports: {},
            members: {},
        },
        5: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 5,
            parent_id: Some(
                0,
            ),
            decls: [
                SymbolDecl {
                    kind: QualifiedTarget(
                        (
                            "Namespace1",
                            #2,
                        ),
                        [
                            "test",
                        ],
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            134,
                        ),
                        end: SourcePos(
                            164,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {},
            exports: {},
            members: {},
        },
        6: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 6,
            parent_id: Some(
                0,
            ),
            decls: [
                SymbolDecl {
                    kind: QualifiedTarget(
                        (
                            "Namespace1",
                            #2,
                        ),
                        [
                            "Inner",
                            "test2",
                        ],
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            165,
                        ),
                        end: SourcePos(
                            203,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {},
            exports: {},
            members: {},
        },
        7: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 7,
            parent_id: Some(
                0,
            ),
            decls: [
                SymbolDecl {
                    kind: Target(
                        (
                            "test",
                            #2,
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            214,
                        ),
                        end: SourcePos(
                            218,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {},
            exports: {},
            members: {},
        },
        8: Symbol {
            module_id: ModuleId(
                0,
            ),
            symbol_id: 8,
            parent_id: Some(
                0,
            ),
            decls: [
                SymbolDecl {
                    kind: Target(
                        (
                            "test2",
                            #2,
                        ),
                    ),
                    range: SourceRange {
                        start: SourcePos(
                            220,
                        ),
                        end: SourcePos(
                            225,
                        ),
                    },
                    flags: 0,
                },
            ],
            child_ids: {},
            exports: {},
            members: {},
        },
    },
}
== export definitions ==
[Namespace1]: file:///mod.ts:0..62
  export namespace Namespace1 {
    export function test() {
    }
  }
file:///mod.ts:63..132
  export namespace Namespace1.Inner {
    export function test2() {
    }
  }
[test]: file:///mod.ts:32..60
  export function test() {
    }
[test2]: file:///mod.ts:101..130
  export function test2() {
    }
