mirror of
https://github.com/apple/pkl.git
synced 2026-01-13 15:13:38 +01:00
[PR #575] [CLOSED] Fix default value evaluation in toTyped() #626
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/apple/pkl/pull/575
Author: @luuvish
Created: 7/12/2024
Status: ❌ Closed
Base:
main← Head:main📝 Commits (2)
66cc30fFix default value evaluation in toTyped()46af485Merge branch 'apple:main' into main📊 Changes
5 files changed (+88 additions, -2 deletions)
View changed files
📝
pkl-core/src/main/java/org/pkl/core/ast/member/DelegateToExtraStorageMapOrParentNode.java(+3 -1)📝
pkl-core/src/main/java/org/pkl/core/ast/member/DelegateToExtraStorageObjOrParentNode.java(+2 -1)📝
pkl-core/src/main/java/org/pkl/core/runtime/VmUtils.java(+36 -0)➕
pkl-core/src/test/files/LanguageSnippetTests/input/api/toTypedWithDefault.pkl(+25 -0)➕
pkl-core/src/test/files/LanguageSnippetTests/output/api/toTypedWithDefault.pcf(+22 -0)📄 Description
Fix the issue where default values defined in the class are not properly
generated when converting Dynamic or Map objects to Typed objects.
Also, fix the issue where values are not properly generated for amended
properties when making amends to the converted Typed objects.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.