-
Notifications
You must be signed in to change notification settings - Fork 1.3k
[core] Support two-argument shorthand for "match" expression #12415
Conversation
If a property getter in mbgl can return a match expression that uses the shorthand, then mapbox-gl-native/platform/darwin/src/NSExpression+MGLAdditions.mm Lines 949 to 962 in 192c611
The usual case for this shorthand would be as part of a predicate rather than an expression set on a property. That’ll already work OK, thanks to this fallback that stuffs the expression in an mapbox-gl-native/platform/darwin/src/NSPredicate+MGLAdditions.mm Lines 157 to 162 in 192c611
It would be nice for Conversely, the latter two arguments to this match expression can be omitted, though there shouldn’t be any functional difference: mapbox-gl-native/platform/darwin/src/NSComparisonPredicate+MGLAdditions.mm Lines 119 to 123 in 192c611
/cc @fabian-guerra |
8a1a6f2
to
42a99f0
Compare
The shorthand is converted to longhand at parse time, so property getters will return the longhand form. |
This was added in gl-js in #7095.
42a99f0
to
bb151d1
Compare
This pull request has been automatically detected as stale because it has not had recent activity and will be archived. Thank you for your contributions. |
|
Companion to mapbox/mapbox-gl-js#6964.
Dependent on getting some ignores or fixes for some new render tests (cc @ChrisLoer):
symbol-placement: line-center
to native #12337@1ec5 Does this require any
NSExpression
-related work?It looks like it should fit into this Android API naturally. I think it should have had a
@Size(min = 4)
annotation, but after this change@Size(min = 2)
is correct. cc @tobrun