Closed axoking closed 6 months ago
I randomly found a bug in the compiler that panics with the following message:
i-slint-compiler-1.5.1/llr/lower_expression.rs:35:34: called `Option::unwrap()` on a `None` value
It appears under some weird circumstances. I was able to reproduce it like this:
For example:
component MyComponent inherits Rectangle { animate background {} init => { self.background = #000; } } export component MyWindow inherits Window { for _ in [1, 2, 3]: MyComponent {} }
That bug also appears in SlintPad, it freezes the preview window and prints a similar error message in the JS console.
Thanks for the bug report. I can reproduce the issue. The problem is that the init callback is inlined in the wrong item tree. Most likely caused by https://github.com/slint-ui/slint/pull/4322 )
I randomly found a bug in the compiler that panics with the following message:
It appears under some weird circumstances. I was able to reproduce it like this:
For example:
That bug also appears in SlintPad, it freezes the preview window and prints a similar error message in the JS console.