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

Convert type assertion expressions to NSExpression #11004

Closed
4 tasks
1ec5 opened this issue Jan 24, 2018 · 1 comment
Closed
4 tasks

Convert type assertion expressions to NSExpression #11004

1ec5 opened this issue Jan 24, 2018 · 1 comment
Labels
GL JS parity For feature parity with Mapbox GL JS iOS Mapbox Maps SDK for iOS macOS Mapbox Maps SDK for macOS runtime styling

Comments

@1ec5
Copy link
Contributor

1ec5 commented Jan 24, 2018

The NSExpression-based property value implementation in #10726 should be able to express the type assertion operators defined in the style specification:

The coercion operators corresponding to these operators (literal, to-boolean, to-number, and to-string) have already been implemented.

Additionally, typeof needs to be implemented.

@1ec5 1ec5 added GL JS parity For feature parity with Mapbox GL JS iOS Mapbox Maps SDK for iOS macOS Mapbox Maps SDK for macOS runtime styling labels Jan 24, 2018
@1ec5 1ec5 added this to the ios-v4.0.0 milestone Jan 24, 2018
@1ec5
Copy link
Contributor Author

1ec5 commented Apr 17, 2018

All these operators can now be expressed by the last-ditch MGL_FUNCTION function. In practice, there should be little need for iOS and macOS developers to explicitly use these operators, compared to more ergonomic, built-in CAST operator.

@1ec5 1ec5 closed this as completed Apr 17, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
GL JS parity For feature parity with Mapbox GL JS iOS Mapbox Maps SDK for iOS macOS Mapbox Maps SDK for macOS runtime styling
Projects
None yet
Development

No branches or pull requests

1 participant