pkl / PR 1461

Add `import` destructuring and `amends`/`extends` of classes within modules

apple/pkl#1461 openmixed

+529/−70lines
37files
0comments
2026-03-03opened
-merged

What it touches

test: 22 main: 15

Modules: pkl-core (23), pkl-parser (9), pkl-formatter (5)

Architectural impact (arcade-agent diff_impact)

11files mapped to the graph
334entities in those files
Core, Parsercomponents
2497entities within 3 hops downstream

Most depended-upon changed entities

EntityDependents
org.pkl.core.ast.type.UnresolvedTypeNode310
org.pkl.parser.ParserVisitor167
org.pkl.parser.Parser117
org.pkl.core.ast.builder.AstBuilder80
org.pkl.parser.syntax.ExtendsOrAmendsClause80
org.pkl.core.repl.ReplServer7
org.pkl.parser.BaseParserVisitor5
org.pkl.parser.GenericParser3

Computed against the current default branch, not the PR base commit; files renamed or deleted since then are unmatched. Downstream counts are a reverse-dependency closure to depth 3 and over-approximate real blast radius.

Files

mainpkl-core/src/main/java/org/pkl/core/ast/builder/AstBuilder.java
mainpkl-core/src/main/java/org/pkl/core/ast/expression/literal/AmendModuleNode.java
mainpkl-core/src/main/java/org/pkl/core/ast/type/UnresolvedTypeNode.java
mainpkl-core/src/main/java/org/pkl/core/repl/ReplServer.java
mainpkl-core/src/main/resources/org/pkl/core/errorMessages.properties
testpkl-core/src/test/files/LanguageSnippetTests/input-helper/modules/amendModuleClass.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input-helper/modules/amendModuleValue.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input-helper/modules/extendModuleClass.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input-helper/modules/extendModuleValue.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input/basic/import4.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input/basic/import5.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input/basic/imported.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input/basic/imported2.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input/modules/amendModule7.pkl
testpkl-core/src/test/files/LanguageSnippetTests/input/modules/extendModule2.pkl
testpkl-core/src/test/files/LanguageSnippetTests/output/basic/import4.pcf
testpkl-core/src/test/files/LanguageSnippetTests/output/basic/import5.err
testpkl-core/src/test/files/LanguageSnippetTests/output/basic/imported.pcf
testpkl-core/src/test/files/LanguageSnippetTests/output/basic/imported2.pcf
testpkl-core/src/test/files/LanguageSnippetTests/output/modules/amendModule7.pcf
testpkl-core/src/test/files/LanguageSnippetTests/output/modules/amendModuleClass.err
testpkl-core/src/test/files/LanguageSnippetTests/output/modules/amendModuleValue.err
testpkl-core/src/test/files/LanguageSnippetTests/output/modules/extendModule2.pcf
mainpkl-formatter/src/main/kotlin/org/pkl/formatter/Builder.kt
testpkl-formatter/src/test/files/FormatterSnippetTests/input/imports.pkl
testpkl-formatter/src/test/files/FormatterSnippetTests/input/module-definitions.pkl
testpkl-formatter/src/test/files/FormatterSnippetTests/output/imports.pkl
testpkl-formatter/src/test/files/FormatterSnippetTests/output/module-definitions.pkl
mainpkl-parser/src/main/java/org/pkl/parser/BaseParserVisitor.java
mainpkl-parser/src/main/java/org/pkl/parser/GenericParser.java
mainpkl-parser/src/main/java/org/pkl/parser/Parser.java
mainpkl-parser/src/main/java/org/pkl/parser/ParserVisitor.java
mainpkl-parser/src/main/java/org/pkl/parser/syntax/ExtendsOrAmendsClause.java
mainpkl-parser/src/main/java/org/pkl/parser/syntax/ImportClause.java
mainpkl-parser/src/main/java/org/pkl/parser/syntax/ImportDeconstruction.java
mainpkl-parser/src/main/java/org/pkl/parser/syntax/ImportDeconstructionList.java
mainpkl-parser/src/main/java/org/pkl/parser/syntax/generic/NodeType.java