You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte/test/js/samples/loop-protect/input.svelte

23 lines
316 B

<script>
let node;
function foo() {
const guard = 'foo';
while(true) {
console.log(guard);
}
}
while(true) {
foo();
}
for(;;) {
foo();
}
while(true) foo();
$: while(true) foo();
do foo(); while(true);
$: do foo(); while(true);
</script>
<div bind:this={node}></div>