Fix incorrect member links (#1723)

This fixes various incorrect member links in the stdlib.
This commit is contained in:
Daniel Chao
2026-07-02 11:04:01 -07:00
committed by GitHub
parent 1c1a39e37f
commit 45912c504f
10 changed files with 40 additions and 73 deletions
+1 -1
View File
@@ -16,7 +16,7 @@
/// Defines inputs and outputs for CLI commands implemented in Pkl. /// Defines inputs and outputs for CLI commands implemented in Pkl.
/// ///
/// Modules extending `pkl:Command` may configure [ModuleOutput.text], [ModuleOutput.bytes], and/or /// Modules extending `pkl:Command` may configure [FileOutput.text], [FileOutput.bytes], and/or
/// [ModuleOutput.files] of [output] to influence the effect of the command. /// [ModuleOutput.files] of [output] to influence the effect of the command.
/// ///
/// Command modules should override [options] and provide their own class declaring options: /// Command modules should override [options] and provide their own class declaring options:
-1
View File
@@ -21,7 +21,6 @@ module pkl.EvaluatorSettings
import "pkl:EvaluatorSettings" import "pkl:EvaluatorSettings"
import "pkl:platform" import "pkl:platform"
// used by doc comments
import "pkl:Project" import "pkl:Project"
/// The external properties available to Pkl, read using the `prop:` scheme. /// The external properties available to Pkl, read using the `prop:` scheme.
+9 -9
View File
@@ -16,8 +16,8 @@
/// A manifest that defines the presence of a project. /// A manifest that defines the presence of a project.
/// ///
/// A project is useful for defining [dependencies], and also for defining common evaluator /// A project is useful for defining [dependencies], and also for
/// [settings]. /// [common evaluator settings][evaluatorSettings].
/// ///
/// A project is a directory that contains a project file at its root. /// A project is a directory that contains a project file at its root.
/// The project file is a file named `PklProject` exactly, that amends or embeds `"pkl:Project"`. /// The project file is a file named `PklProject` exactly, that amends or embeds `"pkl:Project"`.
@@ -26,8 +26,8 @@
/// `--project-dir` flag, or is determined implicitly by walking up the working directory, looking /// `--project-dir` flag, or is determined implicitly by walking up the working directory, looking
/// for a directory containing a `PklProject` file. /// for a directory containing a `PklProject` file.
/// ///
/// When using the API libraries (e.g. _pkl-swift_, _pkl-go_ or _pkl-config-java_), the project must be /// When using the API libraries (e.g. _pkl-swift_, _pkl-go_ or _pkl-config-java_), the project must
/// explicitly stated via the evaluator builder. /// be explicitly stated via the evaluator builder.
/// ///
/// ## Embedding [Project] /// ## Embedding [Project]
/// ///
@@ -193,11 +193,11 @@ local isFileBasedProject = projectFileUri.startsWith("file:")
/// ///
/// The following values can only be set if this is a file-based project: /// The following values can only be set if this is a file-based project:
/// ///
/// - [modulePath][EvaluatorSettings.modulePath] /// - [modulePath][EvaluatorSettingsModule.modulePath]
/// - [rootDir][EvaluatorSettings.rootDir] /// - [rootDir][EvaluatorSettingsModule.rootDir]
/// - [moduleCacheDir][EvaluatorSettings.moduleCacheDir] /// - [moduleCacheDir][EvaluatorSettingsModule.moduleCacheDir]
/// - [externalModuleReaders][EvaluatorSettings.externalModuleReaders] /// - [externalModuleReaders][EvaluatorSettingsModule.externalModuleReaders]
/// - [externalResourceReaders][EvaluatorSettings.externalResourceReaders] /// - [externalResourceReaders][EvaluatorSettingsModule.externalResourceReaders]
evaluatorSettings: EvaluatorSettingsModule( evaluatorSettings: EvaluatorSettingsModule(
(modulePath != null).implies(isFileBasedProject), (modulePath != null).implies(isFileBasedProject),
(rootDir != null).implies(isFileBasedProject), (rootDir != null).implies(isFileBasedProject),
+3 -4
View File
@@ -20,7 +20,6 @@
@ModuleInfo { minPklVersion = "0.32.0" } @ModuleInfo { minPklVersion = "0.32.0" }
module pkl.base module pkl.base
// json, math, and yaml imports used for doc comments
import "pkl:json" import "pkl:json"
import "pkl:jsonnet" import "pkl:jsonnet"
import "pkl:math" import "pkl:math"
@@ -3227,16 +3226,16 @@ external class List<out Element> extends Collection<Element> {
/// Returns [null] if [index] is outside the bounds of this list. /// Returns [null] if [index] is outside the bounds of this list.
external function replaceOrNull<Other>(index: Int, replacement: Other): List<Element | Other>? external function replaceOrNull<Other>(index: Int, replacement: Other): List<Element | Other>?
/// Replaces the elements between indices [range] and [exclusiveEnd] with [replacement]. /// Replaces the elements between indices [start] and [exclusiveEnd] with [replacement].
/// ///
/// Throws if [range] or [exclusiveEnd] is outside the bounds of this list. /// Throws if [start] or [exclusiveEnd] is outside the bounds of this list.
external function replaceRange<Other>( external function replaceRange<Other>(
start: Int, start: Int,
exclusiveEnd: Int, exclusiveEnd: Int,
replacement: Collection<Other>, replacement: Collection<Other>,
): List<Element | Other> ): List<Element | Other>
/// Replaces the elements between indices [range] and [exclusiveEnd] with [replacement]. /// Replaces the elements between indices [start] and [exclusiveEnd] with [replacement].
/// ///
/// Returns [null] if [range] or [exclusiveEnd] is outside the bounds of this list. /// Returns [null] if [range] or [exclusiveEnd] is outside the bounds of this list.
external function replaceRangeOrNull<Other>( external function replaceRangeOrNull<Other>(
+1 -1
View File
@@ -54,7 +54,7 @@ class Parser {
/// Value converters to apply to parsed values. /// Value converters to apply to parsed values.
/// ///
/// For further information see [PcfRenderer.converters]. /// For further information see [BaseValueRenderer.converters].
converters: Mapping<Class | String(!isEmpty), (unknown) -> unknown> converters: Mapping<Class | String(!isEmpty), (unknown) -> unknown>
/// Parses [source] as a JSON document. /// Parses [source] as a JSON document.
+1 -1
View File
@@ -44,7 +44,7 @@ function ExtVar(_name: String): ExtVar = new { name = _name }
/// | [Typed] | object | /// | [Typed] | object |
/// ///
/// Some Pkl types, such as [Duration] and [DataSize], don't have a Jsonnet equivalent. /// Some Pkl types, such as [Duration] and [DataSize], don't have a Jsonnet equivalent.
/// To render values of such types, define _output converters_ (see [Renderer.converters]). /// To render values of such types, define _output converters_ (see [BaseValueRenderer.converters]).
/// ///
/// The output is formatted according to _jsonnetfmt_. /// The output is formatted according to _jsonnetfmt_.
/// To render an `importstr` construct, use [ImportStr()]. /// To render an `importstr` construct, use [ImportStr()].
+22 -53
View File
@@ -63,101 +63,70 @@ external maxUInt32: UInt32
/// The minimum finite [Float] value: `-1.7976931348623157e308`. /// The minimum finite [Float] value: `-1.7976931348623157e308`.
/// ///
/// Operations whose value is less than [minFiniteFloat] return -[infinity]. /// Operations whose value is less than [minFiniteFloat] return -[Infinity].
external minFiniteFloat: Float external minFiniteFloat: Float
/// The maximum finite [Float] value: `1.7976931348623157e308`. /// The maximum finite [Float] value: `1.7976931348623157e308`.
/// ///
/// Operations whose value is greater than [maxFiniteFloat] return [infinity]. /// Operations whose value is greater than [maxFiniteFloat] return [Infinity].
external maxFiniteFloat: Float external maxFiniteFloat: Float
/// The minimum positive [Float] value that is greater than zero: `4.9e-324`. /// The minimum positive [Float] value that is greater than zero: `4.9e-324`.
external minPositiveFloat: Float external minPositiveFloat: Float
/// The number [e][1]. /// The number [e](https://en.wikipedia.org/wiki/E_(mathematical_constant)).
///
/// [1]: https://en.wikipedia.org/wiki/E_(mathematical_constant)
external e: Float external e: Float
/// The number [π][1]. /// The number [π](https://en.wikipedia.org/wiki/Pi).
///
/// [1]: https://en.wikipedia.org/wiki/Pi
external pi: Float external pi: Float
/// Returns e raised to the power of [exponent]. /// Returns e [raised to the power](https://en.wikipedia.org/wiki/Exponential_function) of
/// /// [exponent].
/// [1]: https://en.wikipedia.org/wiki/Exponential_function
external function exp(exponent: Number): Float external function exp(exponent: Number): Float
/// Returns the [square root][1] of [x]. /// Returns the [square root](https://en.wikipedia.org/wiki/Square_root) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Square_root
external function sqrt(x: Number): Float external function sqrt(x: Number): Float
/// Returns the [cube root][1] of [x]. /// Returns the [cube root](https://en.wikipedia.org/wiki/Cube_root) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Cube_root
external function cbrt(x: Number): Float external function cbrt(x: Number): Float
/// Returns the [natural logarithm][1] (base e logarithm) of [x]. /// Returns the [natural logarithm](https://en.wikipedia.org/wiki/Natural_logarithm) (base e logarithm) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Natural_logarithm
external function log(x: Number): Float external function log(x: Number): Float
/// Returns the [base 2 logarithm][1] of [x]. /// Returns the [base 2 logarithm](https://en.wikipedia.org/wiki/Binary_logarithm) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Binary_logarithm
external function log2(x: Number): Float external function log2(x: Number): Float
/// Returns the [base 10 logarithm][1] of [x]. /// Returns the [base 10 logarithm](https://en.wikipedia.org/wiki/Common_logarithm) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Common_logarithm
external function log10(x: Number): Float external function log10(x: Number): Float
/// Returns the [sine][1] of [angle] given in radians. /// Returns the [sine](https://en.wikipedia.org/wiki/Sine_and_cosine) of [angle] given in radians.
///
/// [1]: https://en.wikipedia.org/wiki/Sine
external function sin(angle: Number): Float external function sin(angle: Number): Float
/// Returns the [cosine][1] of [angle] given in radians. /// Returns the [cosine](https://en.wikipedia.org/wiki/Sine_and_cosine) of [angle] given in radians.
///
/// [1]: https://en.wikipedia.org/wiki/Trigonometric_functions///cosine
external function cos(angle: Number): Float external function cos(angle: Number): Float
/// Returns the [tangent][1] of [angle] given in radians. /// Returns the [tangent](https://en.wikipedia.org/wiki/Tangent) of [angle] given in radians.
///
/// [1]: https://en.wikipedia.org/wiki/Tangent
external function tan(angle: Number): Float external function tan(angle: Number): Float
/// Returns the [arcsine][1] of [x]. /// Returns the [arcsine](https://en.wikipedia.org/wiki/Inverse_trigonometric_functions) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Inverse_trigonometric_functions
external function asin(x: Number): Float external function asin(x: Number): Float
/// Returns the [arccosine][1] of [x]. /// Returns the [arccosine](https://en.wikipedia.org/wiki/Inverse_trigonometric_functions) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Inverse_trigonometric_functions
external function acos(x: Number): Float external function acos(x: Number): Float
/// Returns the [arctangent][1] of [x]. /// Returns the [arctangent](https://en.wikipedia.org/wiki/Inverse_trigonometric_functions) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Inverse_trigonometric_functions
external function atan(x: Number): Float external function atan(x: Number): Float
/// Returns the [2-argument arctangent][1] of [x] and [y]. /// Returns the [2-argument arctangent](https://en.wikipedia.org/wiki/Atan2) of [x] and [y].
///
/// [1]: https://en.wikipedia.org/wiki/Atan2
@Since { version = "0.28.0" } @Since { version = "0.28.0" }
external function atan2(x: Number, y: Number): Float external function atan2(x: Number, y: Number): Float
/// Returns the [greatest common divisor][1] of [x] and [y]. /// Returns the [greatest common divisor](https://en.wikipedia.org/wiki/Greatest_common_divisor) of
/// /// [x] and [y].
/// [1]: https://en.wikipedia.org/wiki/Greatest_common_divisor
external function gcd(x: Int, y: Int): Int external function gcd(x: Int, y: Int): Int
/// Returns the [least common multiple][1] of [x] and [y]. /// Returns the [least common multiple](https://en.wikipedia.org/wiki/Least_common_multiple) of [x]
/// /// and [y].
/// [1]: https://en.wikipedia.org/wiki/Least_common_multiple
external function lcm(x: Int, y: Int): Int external function lcm(x: Int, y: Int): Int
/// Returns `true` if [x] is a power of two. /// Returns `true` if [x] is a power of two.
+1 -1
View File
@@ -31,7 +31,7 @@
@Since { version = "0.32.0" } @Since { version = "0.32.0" }
module pkl.ref module pkl.ref
/// Creates a deferred [Reference] to a value of type [class] in the given [domain] and [data]. /// Creates a deferred [Reference] to a value of type [`class`] in the given [domain] and [data].
/// ///
/// References may only be constructed for single, non-generic class types. /// References may only be constructed for single, non-generic class types.
/// To create a reference to other types (generic classes, union, nullable, constrained, /// To create a reference to other types (generic classes, union, nullable, constrained,
+1 -1
View File
@@ -77,7 +77,7 @@ class Property extends ConvertProperty {
/// Use this method to directly define an XML element /// Use this method to directly define an XML element
/// instead of relying on the default rendering of Pkl values. /// instead of relying on the default rendering of Pkl values.
/// ///
/// To define the XML element's attributes, set the [attributes] property of the `Element` object: /// To define the XML element's attributes, set the `attributes` property of the `Element` object:
/// ``` /// ```
/// order = xml.Element("order") { /// order = xml.Element("order") {
/// attributes { /// attributes {
+1 -1
View File
@@ -73,7 +73,7 @@ class Parser {
/// Value converters to apply to parsed values. /// Value converters to apply to parsed values.
/// ///
/// For further information see [PcfRenderer.converters]. /// For further information see [BaseValueRenderer.converters].
converters: Mapping<Class | String(!isEmpty), (unknown) -> unknown> converters: Mapping<Class | String(!isEmpty), (unknown) -> unknown>
/// The maximum number of aliases for collection nodes. /// The maximum number of aliases for collection nodes.