mirror of
https://github.com/i-net-software/JWebAssembly.git
synced 2025-03-25 23:47:51 +01:00
test for partial lambda code
This commit is contained in:
parent
f64ed4feee
commit
800edc837d
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2017 - 2018 Volker Berlin (i-net software)
|
* Copyright 2017 - 2020 Volker Berlin (i-net software)
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
@ -96,4 +96,19 @@ public class RuntimeErrors {
|
|||||||
@Export
|
@Export
|
||||||
native static float function();
|
native static float function();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void lambdas() throws IOException {
|
||||||
|
compileErrorTest( "InvokeDynamic/Lambda is not supported.", LambdaMethod.class );
|
||||||
|
}
|
||||||
|
|
||||||
|
static class LambdaMethod {
|
||||||
|
private static int counter;
|
||||||
|
|
||||||
|
@Export
|
||||||
|
static void runnable() {
|
||||||
|
Runnable run = () -> counter++;
|
||||||
|
run.run();
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user