Nimble: Compiler Warnings when using SPM

Created on 11 Jun 2018  路  5Comments  路  Source: Quick/Nimble

  • [x] I have read CONTRIBUTING and have done my best to follow them.

What did you do?

Compiles my project

What did you expect to happen?

There are no warnings if I use simple

What actually happened instead?

I got 32 Warnings (when running in xcode or swift test). Mostly because of 'Matcher' is deprecated:

I know this is related to https://github.com/Quick/Nimble/issues/452 and https://github.com/Quick/Nimble/issues/463 but this isn't fixed when using the package-manager

Environment

List the software versions you're using:

  • Nimble: 7.1.1
  • Xcode Version: Version 9.4 (9F1027a)
  • Swift Version: Apple Swift version 4.1.2 (swiftlang-902.0.54 clang-902.0.39.2) and ubuntu 16.04

Please also mention which package manager you used and its version. Delete the
other package managers in this list:

  • Swift Package Manager: Apple Swift version 4.1.2 (swiftlang-902.0.54 clang-902.0.39.2)

Project that demonstrates the issue

  1. swift package init
  2. add .package(url: "https://github.com/Quick/Nimble.git", .upToNextMajor(from: "7.1.1")), to dependencies in package.swift
  3. add Nimble to dependencies in the testTarget
  4. run swift test or swift package generate-xcodeproj and compile the project in xcode
question / needs more details

All 5 comments

I don't think there is a way to suppress such warnings from the package author side, unfortunately.

But you can achieve it on your side (consumer side): $ swift test -Xswiftc -suppress-warnings

Closing this due to inactivity.

This is still happening to me as of may 2020, what's up with that @ikesyo ?

Deprecation warnings remain until the deprecation roadmap completes at Nimble v10.

Unfortunately in Swift there is no equivalent of #pragma clang diagnostic ignored "-Wdeprecated-implementations" available in ObjC.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

delebedev picture delebedev  路  4Comments

sreddy100 picture sreddy100  路  4Comments

Blackjacx picture Blackjacx  路  7Comments

Blackjacx picture Blackjacx  路  9Comments

ScottRobbins picture ScottRobbins  路  7Comments