Skip to content

Commit 3d11534

Browse files
slandellenormanmaurer
authored andcommitted
Fix type inference w/ JDK8
Motivation: Compile crash w/ JDK8: ``` [ERROR] /Users/slandelle/Documents/dev/workspaces/workspace-ahc2/async-http-clie nt-project/netty-bp/codec-dns/src/main/java/io/netty/handler/codec/dns/D nsMessageUtil.java:[176,16] reference to append is ambiguous both method append(java.lang.String) in java.lang.StringBuilder and method append(java.lang.StringBuffer) in java.lang.StringBuilder match ``` Modification: Force type explicitly Result: Class compile w/ JDK8
1 parent d6bf388 commit 3d11534

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

codec-dns/src/main/java/io/netty/handler/codec/dns/DnsMessageUtil.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ private static void appendRecords(StringBuilder buf, DnsMessage message, DnsSect
173173
for (int i = 0; i < count; i ++) {
174174
buf.append(StringUtil.NEWLINE)
175175
.append(StringUtil.TAB)
176-
.append(message.recordAt(section, i));
176+
.append(message.<DnsRecord>recordAt(section, i));
177177
}
178178
}
179179

0 commit comments

Comments
 (0)