Skip to content

FlowNodeKind::BranchLabel 应该要有条件地联合 #626

Closed

Description

@xuhuanzy
    #[test]
    fn test_table_narrow() {
        let mut ws = VirtualWorkspace::new();
        ws.def(
            r#"
                ---@type table<int, table<int,table>>
                local archiveCache = {}

                local playerCache = archiveCache[0]
                if not playerCache then
                    playerCache = {}
                end

                A = playerCache -- 此时是 table | table<integer,table>, 但他应该为 table<integer,table>
            "#,
        );
        let a = ws.expr_ty("A");
        assert_eq!(ws.humanize_type(a), "table<integer,table>");
    }

Activity

  1. added 2 commits that reference this issue on Jun 22, 2026
    6bae8b3
    a8bb7df
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions