Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Rework spec function/expression taxonomy (counterpart of gl-js#6521) #11861

Merged
merged 6 commits into from
May 14, 2018

Conversation

lbud
Copy link
Contributor

@lbud lbud commented May 7, 2018

This PR is mostly minor tweaks to codegen scripts to account for the spec taxonomy changes described in mapbox/mapbox-gl-js#6521, plus a few ignores needed to update the gl-js pin. (Nitpick test is failing until that PR is merged to master.)

@lbud lbud requested a review from jfirebaugh May 7, 2018 22:45
Copy link
Contributor

@jfirebaugh jfirebaugh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general, instead of updating the definition of isDataDriven, we should replace its uses with a switch on property-type.

};

global.isInterpolable = function(property) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't seem to be used.

@@ -319,9 +319,9 @@ global.propertyDoc = function (propertyName, property, layerType, kind) {
'* Conditional expressions\n' +
'* Variable assignments and references to assigned variables\n';
const inputVariable = property.name === 'heatmap-color' ? '$heatmapDensity' : '$zoomLevel';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this use expression.parameters?

@@ -164,7 +164,7 @@ namespace mbgl {

<% if (property.name === 'heatmap-color') { -%>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this use property-type?

@lbud
Copy link
Contributor Author

lbud commented May 9, 2018

👍 I left a few uses of isDataDriven as is (in platform/darwin) because those uses are less switches on various property types and more binary property function-vs-not.

@lbud lbud merged commit 62c875e into master May 14, 2018
@lbud lbud deleted the lbud-expression-spec branch May 14, 2018 19:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants