Skip to content

Compile Error when targeting macOS/tvOS using Xcode 10 #380

@JonathanDowning

Description

@JonathanDowning

Platform

  • iOS
  • macOS
  • tvOS

In app purchase type

  • Consumable
  • Non-consumable
  • Auto-Renewable Subscription
  • Non-Renewing Subscription

Environment

  • Sandbox
  • Production

Version

0.13.2

Related issues

N/A

Report

Issue summary

SwiftyStoreKit will not compile for macOS/tvOS using Xcode 10, the following error is emitted:

Cannot override 'paymentQueue' which has been marked unavailable
at this location:

https://github.com/bizz84/SwiftyStoreKit/blob/master/SwiftyStoreKit/PaymentQueueController.swift#L242

This is because

- (BOOL)paymentQueue:(SKPaymentQueue *)queue shouldAddStorePayment:(SKPayment *)payment forProduct:(SKProduct *)product NS_SWIFT_NAME(paymentQueue(_:shouldAddStorePayment:for:))

is marked as NS_AVAILABLE_IOS(11_0);

What did you expect to happen

SwiftyStoreKit should compile on macOS/tvOS.

What happened instead

Compilation fails due to the aforementioned error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions