@malloydata/render 0.0.159-dev240805173126 → 0.0.159

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -38081,13 +38081,14 @@ class FL extends CAe.SpaceEntry {
38081
38081
  Xu.SpaceParam = FL;
38082
38082
  class bAe extends FL {
38083
38083
  constructor(e) {
38084
- super(), this.astParam = e;
38084
+ super(), this.astParam = e, this._parameter = void 0;
38085
38085
  }
38086
38086
  parameter() {
38087
- return this.astParam.parameter();
38087
+ return this._parameter !== void 0 ? this._parameter : (this._parameter = this.astParam.parameter(), this._parameter);
38088
38088
  }
38089
38089
  typeDesc() {
38090
- return { dataType: this.astParam.type || "error", expressionType: "scalar", evalSpace: "input" };
38090
+ var e;
38091
+ return { dataType: (e = this.parameter().type) !== null && e !== void 0 ? e : "error", expressionType: "scalar", evalSpace: "constant" };
38091
38092
  }
38092
38093
  }
38093
38094
  Xu.AbstractParameter = bAe;
@@ -47014,7 +47015,15 @@ class d6e extends x6e.MalloyElement {
47014
47015
  var e;
47015
47016
  if (this.default !== void 0) {
47016
47017
  const n = this.default.constantValue();
47017
- return this.type && this.type !== n.dataType && n.dataType !== "error" && this.default.log(`Default value for parameter does not match declared type \`${this.type}\``), !(0, Aq.isCastType)(n.dataType) && n.dataType !== "error" ? (this.default.log(`Default value cannot have type \`${n.dataType}\``), {
47018
+ return this.type && this.type !== n.dataType && n.dataType !== "null" && n.dataType !== "error" && this.default.log(`Default value for parameter does not match declared type \`${this.type}\``), n.dataType === "null" ? this.type ? {
47019
+ value: n.value,
47020
+ name: this.name,
47021
+ type: this.type
47022
+ } : (this.default.log("Default value cannot have type `null` unless parameter type is also specified"), {
47023
+ value: n.value,
47024
+ name: this.name,
47025
+ type: "error"
47026
+ }) : !(0, Aq.isCastType)(n.dataType) && n.dataType !== "error" ? (this.default.log(`Default value cannot have type \`${n.dataType}\``), {
47018
47027
  value: n.value,
47019
47028
  name: this.name,
47020
47029
  type: "error"