slint/internal/compiler/passes
Olivier Goffart 31867fad61
compiler: Reject comparison on unsupported types
The compiler was accepting the comparison of types such as color, or
struct, and then later we'd get rust compilation error or interpreter
panic.

Example seen in the crash reporter:
`internal/interpreter/eval.rs:257:35`
```
unsupported Value::Brush(SolidColor(Color { red: 0, green: 0, blue: 0, alpha: 0 })) ≤ Value::Brush(SolidColor(Color { red: 255, green: 0, blue: 0, alpha: 255 }))
```

Note that some code hapenned to compile with rust or C++.
For example, comparison of bool, or anonymous struct (represented as
tuples), or color represeted as int)
So technically this is a breaking change.
But this should be fine as this was not working in the interpreter and
this is a bug fix.

ChangeLog: Slint compilation error for comparison of types that can't be
compared with less or greater operator.
2025-05-07 11:39:27 +02:00
..
apply_default_properties_from_style.rs Reduce SmolStr <-> &str conversions and copies (#6688) 2024-11-19 10:07:16 +01:00
binding_analysis.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
border_radius.rs Reduce SmolStr <-> &str conversions and copies (#6688) 2024-11-19 10:07:16 +01:00
check_expressions.rs Refactoring: get rid in the callable in the Expression tree 2025-01-24 20:26:35 +01:00
check_public_api.rs compiler: process the import a bit differently 2024-11-14 14:35:22 +01:00
check_rotation.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
clip.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
collect_custom_fonts.rs Refactoring: get rid in the callable in the Expression tree 2025-01-24 20:26:35 +01:00
collect_globals.rs Experimental support for MenuBar 2024-11-20 09:25:37 +01:00
collect_init_code.rs Simplify commercial license (#3063) 2024-05-31 14:06:17 +02:00
collect_structs_and_enums.rs Refactor: use Struct instead of Type for the type in a Expression::Struct 2025-02-03 10:19:30 +01:00
collect_subcomponents.rs Experimental support for MenuBar 2024-11-20 09:25:37 +01:00
compile_paths.rs Refactor: use Struct instead of Type for the type in a Expression::Struct 2025-02-03 10:19:30 +01:00
const_propagation.rs SQUASH: Rework the element id to be a hash based on filename 2025-04-09 13:52:29 +02:00
deduplicate_property_read.rs Compiler: remove more indeterminism in the order of statements 2025-02-15 18:53:44 +01:00
default_geometry.rs Auto-fixed clippy::needless_borrow 2025-02-07 09:02:45 +01:00
embed_glyphs.rs Stabilize the sdf-fonts feature 2025-02-19 21:24:53 +01:00
embed_images.rs compiler: Use BTreeMap at a few more place to help with determinism of the output 2025-02-15 18:53:44 +01:00
ensure_window.rs Allow to have builtin item function to return a value 2025-03-31 14:06:24 +02:00
flickable.rs Fix layout property set in when deriving components 2025-04-23 09:23:07 +02:00
focus_handling.rs compiler: Add a DebugHook expression 2025-04-09 13:52:29 +02:00
generate_item_indices.rs MenuItem with for and if 2025-01-30 10:08:22 +01:00
infer_aliases_types.rs compiler: Add a DebugHook expression 2025-04-09 13:52:29 +02:00
inject_debug_hooks.rs SQUASH: Rework the element id to be a hash based on filename 2025-04-09 13:52:29 +02:00
inlining.rs Fix layout property set in when deriving components 2025-04-23 09:23:07 +02:00
lower_absolute_coordinates.rs Refactor: use Struct instead of Type for the type in a Expression::Struct 2025-02-03 10:19:30 +01:00
lower_accessibility.rs compiler: Add a DebugHook expression 2025-04-09 13:52:29 +02:00
lower_component_container.rs janitor: Fix clippy "unneeded return" 2024-06-24 14:59:47 +02:00
lower_layout.rs SQUASH: Rework the element id to be a hash based on filename 2025-04-09 13:52:29 +02:00
lower_menus.rs Menubar: fix native menus 2025-04-23 07:29:14 +02:00
lower_platform.rs Add Platform.os as well as a rudimentary test 2025-05-06 13:06:27 +02:00
lower_popups.rs compiler: Add a DebugHook expression 2025-04-09 13:52:29 +02:00
lower_property_to_element.rs Auto-fixed clippy::needless_borrow 2025-02-07 09:02:45 +01:00
lower_shadows.rs Fix all format arg inlining 2025-02-06 10:16:20 +01:00
lower_states.rs Refactoring: get rid in the callable in the Expression tree 2025-01-24 20:26:35 +01:00
lower_tabwidget.rs Fix all format arg inlining 2025-02-06 10:16:20 +01:00
lower_text_input_interface.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
lower_timers.rs Fix @children next to Timer or PopupWindow 2025-03-21 15:58:55 +01:00
materialize_fake_properties.rs compiler: fix materialize_fake_properties change 2025-02-21 11:16:00 +01:00
move_declarations.rs MenuItem with for and if 2025-01-30 10:08:22 +01:00
optimize_useless_rectangles.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
purity_check.rs Refactoring: get rid in the callable in the Expression tree 2025-01-24 20:26:35 +01:00
remove_aliases.rs Fix change handler with callback 2025-03-20 21:34:52 +01:00
remove_return.rs compiler: Add a DebugHook expression 2025-04-09 13:52:29 +02:00
remove_unused_properties.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
repeater_component.rs MenuItem with for and if 2025-01-30 10:08:22 +01:00
resolve_native_classes.rs Use SmolStr in more places of the compiler infrastructure 2024-10-17 18:04:58 +02:00
resolving.rs compiler: Reject comparison on unsupported types 2025-05-07 11:39:27 +02:00
unique_id.rs Auto-fixed clippy::needless_borrow 2025-02-07 09:02:45 +01:00
visible.rs Auto-fixed clippy::unnecessary_map_or 2025-02-07 09:02:31 +01:00
z_order.rs compiler: Add a DebugHook expression 2025-04-09 13:52:29 +02:00