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.
///
/// 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.
///
/// 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:platform"
// used by doc comments
import "pkl:Project"
/// 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 project is useful for defining [dependencies], and also for defining common evaluator
/// [settings].
/// A project is useful for defining [dependencies], and also for
/// [common evaluator settings][evaluatorSettings].
///
/// 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"`.
@@ -26,8 +26,8 @@
/// `--project-dir` flag, or is determined implicitly by walking up the working directory, looking
/// 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
/// explicitly stated via the evaluator builder.
/// When using the API libraries (e.g. _pkl-swift_, _pkl-go_ or _pkl-config-java_), the project must
/// be explicitly stated via the evaluator builder.
///
/// ## 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:
///
/// - [modulePath][EvaluatorSettings.modulePath]
/// - [rootDir][EvaluatorSettings.rootDir]
/// - [moduleCacheDir][EvaluatorSettings.moduleCacheDir]
/// - [externalModuleReaders][EvaluatorSettings.externalModuleReaders]
/// - [externalResourceReaders][EvaluatorSettings.externalResourceReaders]
/// - [modulePath][EvaluatorSettingsModule.modulePath]
/// - [rootDir][EvaluatorSettingsModule.rootDir]
/// - [moduleCacheDir][EvaluatorSettingsModule.moduleCacheDir]
/// - [externalModuleReaders][EvaluatorSettingsModule.externalModuleReaders]
/// - [externalResourceReaders][EvaluatorSettingsModule.externalResourceReaders]
evaluatorSettings: EvaluatorSettingsModule(
(modulePath != null).implies(isFileBasedProject),
(rootDir != null).implies(isFileBasedProject),
+3 -4
View File
@@ -20,7 +20,6 @@
@ModuleInfo { minPklVersion = "0.32.0" }
module pkl.base
// json, math, and yaml imports used for doc comments
import "pkl:json"
import "pkl:jsonnet"
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.
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>(
start: Int,
exclusiveEnd: Int,
replacement: Collection<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.
external function replaceRangeOrNull<Other>(
+1 -1
View File
@@ -54,7 +54,7 @@ class Parser {
/// 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>
/// Parses [source] as a JSON document.
+1 -1
View File
@@ -44,7 +44,7 @@ function ExtVar(_name: String): ExtVar = new { name = _name }
/// | [Typed] | object |
///
/// 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_.
/// 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`.
///
/// Operations whose value is less than [minFiniteFloat] return -[infinity].
/// Operations whose value is less than [minFiniteFloat] return -[Infinity].
external minFiniteFloat: Float
/// 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
/// The minimum positive [Float] value that is greater than zero: `4.9e-324`.
external minPositiveFloat: Float
/// The number [e][1].
///
/// [1]: https://en.wikipedia.org/wiki/E_(mathematical_constant)
/// The number [e](https://en.wikipedia.org/wiki/E_(mathematical_constant)).
external e: Float
/// The number [π][1].
///
/// [1]: https://en.wikipedia.org/wiki/Pi
/// The number [π](https://en.wikipedia.org/wiki/Pi).
external pi: Float
/// Returns e raised to the power of [exponent].
///
/// [1]: https://en.wikipedia.org/wiki/Exponential_function
/// Returns e [raised to the power](https://en.wikipedia.org/wiki/Exponential_function) of
/// [exponent].
external function exp(exponent: Number): Float
/// Returns the [square root][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Square_root
/// Returns the [square root](https://en.wikipedia.org/wiki/Square_root) of [x].
external function sqrt(x: Number): Float
/// Returns the [cube root][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Cube_root
/// Returns the [cube root](https://en.wikipedia.org/wiki/Cube_root) of [x].
external function cbrt(x: Number): Float
/// Returns the [natural logarithm][1] (base e logarithm) of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Natural_logarithm
/// Returns the [natural logarithm](https://en.wikipedia.org/wiki/Natural_logarithm) (base e logarithm) of [x].
external function log(x: Number): Float
/// Returns the [base 2 logarithm][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Binary_logarithm
/// Returns the [base 2 logarithm](https://en.wikipedia.org/wiki/Binary_logarithm) of [x].
external function log2(x: Number): Float
/// Returns the [base 10 logarithm][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Common_logarithm
/// Returns the [base 10 logarithm](https://en.wikipedia.org/wiki/Common_logarithm) of [x].
external function log10(x: Number): Float
/// Returns the [sine][1] of [angle] given in radians.
///
/// [1]: https://en.wikipedia.org/wiki/Sine
/// Returns the [sine](https://en.wikipedia.org/wiki/Sine_and_cosine) of [angle] given in radians.
external function sin(angle: Number): Float
/// Returns the [cosine][1] of [angle] given in radians.
///
/// [1]: https://en.wikipedia.org/wiki/Trigonometric_functions///cosine
/// Returns the [cosine](https://en.wikipedia.org/wiki/Sine_and_cosine) of [angle] given in radians.
external function cos(angle: Number): Float
/// Returns the [tangent][1] of [angle] given in radians.
///
/// [1]: https://en.wikipedia.org/wiki/Tangent
/// Returns the [tangent](https://en.wikipedia.org/wiki/Tangent) of [angle] given in radians.
external function tan(angle: Number): Float
/// Returns the [arcsine][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Inverse_trigonometric_functions
/// Returns the [arcsine](https://en.wikipedia.org/wiki/Inverse_trigonometric_functions) of [x].
external function asin(x: Number): Float
/// Returns the [arccosine][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Inverse_trigonometric_functions
/// Returns the [arccosine](https://en.wikipedia.org/wiki/Inverse_trigonometric_functions) of [x].
external function acos(x: Number): Float
/// Returns the [arctangent][1] of [x].
///
/// [1]: https://en.wikipedia.org/wiki/Inverse_trigonometric_functions
/// Returns the [arctangent](https://en.wikipedia.org/wiki/Inverse_trigonometric_functions) of [x].
external function atan(x: Number): Float
/// Returns the [2-argument arctangent][1] of [x] and [y].
///
/// [1]: https://en.wikipedia.org/wiki/Atan2
/// Returns the [2-argument arctangent](https://en.wikipedia.org/wiki/Atan2) of [x] and [y].
@Since { version = "0.28.0" }
external function atan2(x: Number, y: Number): Float
/// Returns the [greatest common divisor][1] of [x] and [y].
///
/// [1]: https://en.wikipedia.org/wiki/Greatest_common_divisor
/// Returns the [greatest common divisor](https://en.wikipedia.org/wiki/Greatest_common_divisor) of
/// [x] and [y].
external function gcd(x: Int, y: Int): Int
/// Returns the [least common multiple][1] of [x] and [y].
///
/// [1]: https://en.wikipedia.org/wiki/Least_common_multiple
/// Returns the [least common multiple](https://en.wikipedia.org/wiki/Least_common_multiple) of [x]
/// and [y].
external function lcm(x: Int, y: Int): Int
/// Returns `true` if [x] is a power of two.
+1 -1
View File
@@ -31,7 +31,7 @@
@Since { version = "0.32.0" }
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.
/// 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
/// 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") {
/// attributes {
+1 -1
View File
@@ -73,7 +73,7 @@ class Parser {
/// 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>
/// The maximum number of aliases for collection nodes.