diff --git a/RRuleSwift.xcodeproj/project.pbxproj b/RRuleSwift.xcodeproj/project.pbxproj index 6190a11..f5b5aaf 100644 --- a/RRuleSwift.xcodeproj/project.pbxproj +++ b/RRuleSwift.xcodeproj/project.pbxproj @@ -184,16 +184,16 @@ D31B138E1CA8E02E00D0B863 /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0800; + LastUpgradeCheck = 0900; ORGANIZATIONNAME = Teambition; TargetAttributes = { D31B13961CA8E02E00D0B863 = { CreatedOnToolsVersion = 7.3; - LastSwiftMigration = 0800; + LastSwiftMigration = 0900; }; EB48D1361D641AD6001EE872 = { CreatedOnToolsVersion = 7.3; - LastSwiftMigration = 0800; + LastSwiftMigration = 0900; }; }; }; @@ -277,14 +277,20 @@ CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; @@ -328,14 +334,20 @@ CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; @@ -380,7 +392,8 @@ PRODUCT_NAME = RRuleSwift; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; }; name = Debug; }; @@ -399,7 +412,8 @@ PRODUCT_BUNDLE_IDENTIFIER = "Teambition.RRuleSwift-iOS"; PRODUCT_NAME = RRuleSwift; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; }; name = Release; }; @@ -422,7 +436,8 @@ SKIP_INSTALL = YES; SWIFT_OBJC_INTERFACE_HEADER_NAME = "$(SWIFT_MODULE_NAME).h"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; @@ -446,7 +461,8 @@ SDKROOT = watchos; SKIP_INSTALL = YES; SWIFT_OBJC_INTERFACE_HEADER_NAME = "$(SWIFT_MODULE_NAME).h"; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; diff --git a/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift iOS.xcscheme b/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift iOS.xcscheme index b0b99fc..8024c3e 100644 --- a/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift iOS.xcscheme +++ b/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift iOS.xcscheme @@ -1,6 +1,6 @@ @@ -36,6 +37,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift watchOS.xcscheme b/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift watchOS.xcscheme index dfc6da4..9bc4410 100644 --- a/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift watchOS.xcscheme +++ b/RRuleSwift.xcodeproj/xcshareddata/xcschemes/RRuleSwift watchOS.xcscheme @@ -1,6 +1,6 @@ @@ -36,6 +37,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/RRuleSwiftExample-TodayExtension/Info.plist b/RRuleSwiftExample-TodayExtension/Info.plist index 020b601..f284c85 100644 --- a/RRuleSwiftExample-TodayExtension/Info.plist +++ b/RRuleSwiftExample-TodayExtension/Info.plist @@ -17,11 +17,11 @@ CFBundlePackageType XPC! CFBundleShortVersionString - 0.1.1 + 0.2.0 CFBundleSignature ???? CFBundleVersion - 11 + 12 NSExtension NSExtensionMainStoryboard diff --git a/RRuleSwiftExample-Watch Extension/Info.plist b/RRuleSwiftExample-Watch Extension/Info.plist index 61f800c..ddf308e 100644 --- a/RRuleSwiftExample-Watch Extension/Info.plist +++ b/RRuleSwiftExample-Watch Extension/Info.plist @@ -17,11 +17,11 @@ CFBundlePackageType XPC! CFBundleShortVersionString - 0.1.1 + 0.2.0 CFBundleSignature ???? CFBundleVersion - 11 + 12 NSExtension NSExtensionAttributes diff --git a/RRuleSwiftExample-Watch/Info.plist b/RRuleSwiftExample-Watch/Info.plist index 4335277..fc526b9 100644 --- a/RRuleSwiftExample-Watch/Info.plist +++ b/RRuleSwiftExample-Watch/Info.plist @@ -17,11 +17,11 @@ CFBundlePackageType APPL CFBundleShortVersionString - 0.1.1 + 0.2.0 CFBundleSignature ???? CFBundleVersion - 11 + 12 UISupportedInterfaceOrientations UIInterfaceOrientationPortrait diff --git a/RRuleSwiftExample.xcodeproj/project.pbxproj b/RRuleSwiftExample.xcodeproj/project.pbxproj index 0d5d988..5df60f2 100644 --- a/RRuleSwiftExample.xcodeproj/project.pbxproj +++ b/RRuleSwiftExample.xcodeproj/project.pbxproj @@ -308,12 +308,12 @@ isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0730; - LastUpgradeCheck = 0800; + LastUpgradeCheck = 0900; ORGANIZATIONNAME = Teambition; TargetAttributes = { D31B13771CA8D8E400D0B863 = { CreatedOnToolsVersion = 7.3; - LastSwiftMigration = 0800; + LastSwiftMigration = 0900; }; D325D6451D0574E00021E620 = { CreatedOnToolsVersion = 7.3.1; @@ -321,11 +321,11 @@ }; EB48D17E1D64202E001EE872 = { CreatedOnToolsVersion = 7.3; - LastSwiftMigration = 0800; + LastSwiftMigration = 0900; }; EB48D18A1D64202E001EE872 = { CreatedOnToolsVersion = 7.3; - LastSwiftMigration = 0800; + LastSwiftMigration = 0900; }; }; }; @@ -469,14 +469,20 @@ CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; @@ -517,14 +523,20 @@ CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; @@ -558,7 +570,8 @@ LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = Teambition.RRuleSwiftExample; PRODUCT_NAME = RRuleSwiftExample; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; }; name = Debug; }; @@ -570,7 +583,8 @@ LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = Teambition.RRuleSwiftExample; PRODUCT_NAME = RRuleSwiftExample; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; }; name = Release; }; @@ -583,7 +597,7 @@ PRODUCT_BUNDLE_IDENTIFIER = Teambition.RRuleSwiftExample.TodayExtension; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_VERSION = 4.0; }; name = Debug; }; @@ -596,7 +610,7 @@ PRODUCT_BUNDLE_IDENTIFIER = Teambition.RRuleSwiftExample.TodayExtension; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_VERSION = 4.0; }; name = Release; }; @@ -611,7 +625,8 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = watchos; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = On; + SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; @@ -628,7 +643,8 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = watchos; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = On; + SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; @@ -643,7 +659,8 @@ PRODUCT_NAME = "${TARGET_NAME}"; SDKROOT = watchos; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; @@ -658,7 +675,8 @@ PRODUCT_NAME = "${TARGET_NAME}"; SDKROOT = watchos; SKIP_INSTALL = YES; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.0; TARGETED_DEVICE_FAMILY = 4; WATCHOS_DEPLOYMENT_TARGET = 2.0; }; diff --git a/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample-TodayExtension.xcscheme b/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample-TodayExtension.xcscheme index 58e977d..a9198ab 100644 --- a/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample-TodayExtension.xcscheme +++ b/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample-TodayExtension.xcscheme @@ -1,6 +1,6 @@ @@ -60,6 +61,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "" selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample.xcscheme b/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample.xcscheme index 19cfa9d..737ce73 100644 --- a/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample.xcscheme +++ b/RRuleSwiftExample.xcodeproj/xcuserdata/hongxin.xcuserdatad/xcschemes/RRuleSwiftExample.xcscheme @@ -1,6 +1,6 @@ @@ -45,6 +46,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/RRuleSwiftExample/Base.lproj/Main.storyboard b/RRuleSwiftExample/Base.lproj/Main.storyboard index 3947ea7..1662c26 100644 --- a/RRuleSwiftExample/Base.lproj/Main.storyboard +++ b/RRuleSwiftExample/Base.lproj/Main.storyboard @@ -1,8 +1,12 @@ - - + + + + + - + + @@ -14,12 +18,12 @@ - + - - + + @@ -33,18 +37,18 @@ - - + + - + - + - + @@ -59,14 +63,14 @@ - + - + - + @@ -90,7 +94,7 @@ - + @@ -117,7 +121,7 @@ - + diff --git a/RRuleSwiftExample/Info.plist b/RRuleSwiftExample/Info.plist index 978fb91..d413150 100644 --- a/RRuleSwiftExample/Info.plist +++ b/RRuleSwiftExample/Info.plist @@ -15,11 +15,11 @@ CFBundlePackageType APPL CFBundleShortVersionString - 0.1.1 + 0.2.0 CFBundleSignature ???? CFBundleVersion - 11 + 12 LSRequiresIPhoneOS UILaunchStoryboardName diff --git a/RRuleSwiftExample/RRuleExampleViewController.swift b/RRuleSwiftExample/RRuleExampleViewController.swift index 53b9be7..0d657f5 100644 --- a/RRuleSwiftExample/RRuleExampleViewController.swift +++ b/RRuleSwiftExample/RRuleExampleViewController.swift @@ -96,7 +96,7 @@ class RRuleExampleViewController: UIViewController { print("\n") } - func resetButtonTapped(_ sender: UIBarButtonItem) { + @objc func resetButtonTapped(_ sender: UIBarButtonItem) { rule = RecurrenceRule(frequency: .daily) } } @@ -371,11 +371,11 @@ extension RRuleExampleViewController: UIPickerViewDataSource, UIPickerViewDelega } extension RRuleExampleViewController { - func startDateDidChange(_ datePicker: UIDatePicker) { + @objc func startDateDidChange(_ datePicker: UIDatePicker) { rule.startDate = datePicker.date } - func endDateDidChange(_ datePicker: UIDatePicker) { + @objc func endDateDidChange(_ datePicker: UIDatePicker) { rule.recurrenceEnd = EKRecurrenceEnd(end: datePicker.date) } } diff --git a/Sources/ExclusionDate.swift b/Sources/ExclusionDate.swift index b75f168..0184370 100644 --- a/Sources/ExclusionDate.swift +++ b/Sources/ExclusionDate.swift @@ -24,7 +24,7 @@ public struct ExclusionDate { guard let range = string.range(of: "EXDATE:"), range.lowerBound == string.startIndex else { return nil } - let exdateString = string.substring(from: range.upperBound) + let exdateString = String(string.suffix(from: range.upperBound)) let exdates = exdateString.components(separatedBy: ",").flatMap { (dateString) -> String? in if (dateString.isEmpty || dateString.characters.count == 0) { return nil @@ -47,7 +47,7 @@ public struct ExclusionDate { exdateString += dateStrings.joined(separator: ",") } - if exdateString.substring(from: exdateString.characters.index(exdateString.endIndex, offsetBy: -1)) == "," { + if String(exdateString.suffix(from: exdateString.characters.index(exdateString.endIndex, offsetBy: -1))) == "," { exdateString.remove(at: exdateString.characters.index(exdateString.endIndex, offsetBy: -1)) } diff --git a/Sources/InclusionDate.swift b/Sources/InclusionDate.swift index 14dc66a..36e603a 100644 --- a/Sources/InclusionDate.swift +++ b/Sources/InclusionDate.swift @@ -21,7 +21,7 @@ public struct InclusionDate { guard let range = string.range(of: "RDATE:"), range.lowerBound == string.startIndex else { return nil } - let rdateString = string.substring(from: range.upperBound) + let rdateString = String(string.suffix(from: range.upperBound)) let rdates = rdateString.components(separatedBy: ",").flatMap { (dateString) -> String? in if (dateString.isEmpty || dateString.characters.count == 0) { return nil @@ -43,7 +43,7 @@ public struct InclusionDate { rdateString += dateStrings.joined(separator: ",") } - if rdateString.substring(from: rdateString.characters.index(rdateString.endIndex, offsetBy: -1)) == "," { + if String(rdateString.suffix(from: rdateString.characters.index(rdateString.endIndex, offsetBy: -1))) == "," { rdateString.remove(at: rdateString.characters.index(rdateString.endIndex, offsetBy: -1)) } diff --git a/Sources/Iterators.swift b/Sources/Iterators.swift index 8d3f360..2d0bf15 100644 --- a/Sources/Iterators.swift +++ b/Sources/Iterators.swift @@ -9,15 +9,15 @@ import Foundation import JavaScriptCore -internal struct Iterator { - static let endlessRecurrenceCount = 500 - static let rruleContext: JSContext? = { +public struct Iterator { + public static let endlessRecurrenceCount = 500 + internal static let rruleContext: JSContext? = { guard let rrulejs = JavaScriptBridge.rrulejs() else { return nil } let context = JSContext() context?.exceptionHandler = { context, exception in - print("[RRuleSwift] rrule.js error: \(exception)") + print("[RRuleSwift] rrule.js error: \(String(describing: exception))") } let _ = context?.evaluateScript(rrulejs) return context diff --git a/Sources/JavaScriptBridge.swift b/Sources/JavaScriptBridge.swift index aa6b2a0..364261e 100644 --- a/Sources/JavaScriptBridge.swift +++ b/Sources/JavaScriptBridge.swift @@ -145,7 +145,7 @@ internal extension RecurrenceRule { jsonString += "bysecond: [\(bysecondStrings.joined(separator: ","))]" } - if jsonString.substring(from: jsonString.characters.index(jsonString.endIndex, offsetBy: -1)) == "," { + if String(jsonString.suffix(from: jsonString.characters.index(jsonString.endIndex, offsetBy: -1))) == "," { jsonString.remove(at: jsonString.characters.index(jsonString.endIndex, offsetBy: -1)) } diff --git a/Sources/RRule.swift b/Sources/RRule.swift index cb7bde9..0dc790d 100644 --- a/Sources/RRule.swift +++ b/Sources/RRule.swift @@ -29,7 +29,7 @@ public struct RRule { guard let range = string.range(of: "RRULE:"), range.lowerBound == string.startIndex else { return nil } - let ruleString = string.substring(from: range.upperBound) + let ruleString = String(string.suffix(from: range.upperBound)) let rules = ruleString.components(separatedBy: ";").flatMap { (rule) -> String? in if (rule.isEmpty || rule.characters.count == 0) { return nil @@ -268,7 +268,7 @@ public struct RRule { rruleString += "BYSECOND=\(bysecondStrings.joined(separator: ","));" } - if rruleString.substring(from: rruleString.characters.index(rruleString.endIndex, offsetBy: -1)) == ";" { + if String(rruleString.suffix(from: rruleString.characters.index(rruleString.endIndex, offsetBy: -1))) == ";" { rruleString.remove(at: rruleString.characters.index(rruleString.endIndex, offsetBy: -1)) } diff --git a/Sources/Supporting Files/Info-iOS.plist b/Sources/Supporting Files/Info-iOS.plist index 44122f8..6019f05 100644 --- a/Sources/Supporting Files/Info-iOS.plist +++ b/Sources/Supporting Files/Info-iOS.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 0.1.1 + 0.2.0 CFBundleSignature ???? CFBundleVersion diff --git a/Sources/Supporting Files/Info-watchOS.plist b/Sources/Supporting Files/Info-watchOS.plist index 44122f8..6019f05 100644 --- a/Sources/Supporting Files/Info-watchOS.plist +++ b/Sources/Supporting Files/Info-watchOS.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 0.1.1 + 0.2.0 CFBundleSignature ???? CFBundleVersion