fix(serialize): support different exception types in copyTo
ci/woodpecker/push/woodpecker Pipeline was successful Details

This commit is contained in:
Johannes Frohnmeyer 2024-04-13 20:47:34 +02:00
parent f03763f86d
commit 7335bb63c8
Signed by: Johannes
GPG Key ID: E76429612C2929F4
1 changed files with 1 additions and 1 deletions

View File

@ -70,7 +70,7 @@ public abstract class SerializeReader<TEx extends Throwable, T extends Serialize
* @param writer the writer to copy to
* @throws TEx if an error occurs
*/
public void copyTo(SerializeWriter<TEx, ?> writer) throws TEx {
public <TEx2 extends Throwable> void copyTo(SerializeWriter<TEx2, ?> writer) throws TEx, TEx2 {
switch (peek()) {
case BEGIN_ARRAY -> {
this.beginArray();