mirror of
https://github.com/netbirdio/gomobile-tvos-fork.git
synced 2026-05-22 18:43:29 -07:00
mobile/bind/objc: treat warnings as errors in SeqTest.m
Warnings used to be invisible when running SeqTest.m through go test. Treat warnings as errors and fix a bug that surfaced. Change-Id: I81e7291635824cdb4a898c91db740f7aa10f3611 Reviewed-on: https://go-review.googlesource.com/21133 Reviewed-by: David Crawshaw <crawshaw@golang.org>
This commit is contained in:
+1
-1
@@ -369,7 +369,7 @@ static int numI = 0;
|
||||
|
||||
- (void)testIDup {
|
||||
Number *want = [[Number alloc] init];
|
||||
Number *got = GoTestpkgIDup(want);
|
||||
Number *got = (Number *)GoTestpkgI2Dup(want);
|
||||
XCTAssertEqual(got, want, @"ObjC object passed through Go should not be wrapped");
|
||||
}
|
||||
|
||||
|
||||
@@ -189,6 +189,7 @@
|
||||
"DEBUG=1",
|
||||
"$(inherited)",
|
||||
);
|
||||
GCC_TREAT_WARNINGS_AS_ERRORS = YES;
|
||||
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
||||
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
||||
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
||||
@@ -227,6 +228,7 @@
|
||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||
GCC_C_LANGUAGE_STANDARD = gnu99;
|
||||
GCC_NO_COMMON_BLOCKS = YES;
|
||||
GCC_TREAT_WARNINGS_AS_ERRORS = YES;
|
||||
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
|
||||
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
|
||||
GCC_WARN_UNDECLARED_SELECTOR = YES;
|
||||
|
||||
@@ -143,6 +143,10 @@ func NumSCollected() int {
|
||||
return numSCollected
|
||||
}
|
||||
|
||||
func I2Dup(i I2) I2 {
|
||||
return i
|
||||
}
|
||||
|
||||
func IDup(i I) I {
|
||||
return i
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user