Skip to content

Starlark types #22935

@comius

Description

@comius

Support type annotations and type checking in Starlark

The first goal is: correctness and readability of Starlark code

Other goals are:

  • improving efficiency of Starlark interpreter and
  • Bazel tech-debt reduction

Roadmap:

Milestone 1 (Q4 2024) - MVP - Bootstraping Starlark types

Design doc: SEP-001 Bootstrapping Starlark types

Starlark specification is incrementally extended under the starlark-with-types branch: https://github.com/bazelbuild/starlark/blob/starlark-with-types/spec.md

Goal: Provide a minimally viable type system in Starlark

Milestone 2 - Static type checking and type inference

Backlog

  • Providers/classes
  • Types for Rules & Symbolic macros
  • Types for selects
  • Types for Java-Starlark interface / Java annotations
  • Support types in tooling & IDEs

Metadata

Metadata

Assignees

Labels

P1I'll work on this now. (Assignee required)team-Starlark-InterpreterIssues involving the Starlark interpreter used by Bazeltype: feature request

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions