Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix C++ build breakage caused by changed in stringify! output in ni… #5412

Merged
merged 1 commit into from
Jun 15, 2024

Conversation

ogoffart
Copy link
Member

…ghtly Rust

The C++ build started failling with nightly rust:
rust-lang/rust#125174 changed the output of strignify! to contins more spaces between tokens, which we relied on to perform some type substitution from Rust types to C++ types, resulting in compilation errors:

build/api/cpp/generated_include/slint_builtin_structs_internal.h:71:5: error: ‘Option’ does not name a type
   71 |     Option < core :: ops :: Range < i32 >> replacement_range;
      |     ^~~~~~
build/api/cpp/generated_include/slint_builtin_structs_internal.h:75:14: error: ‘core’ was not declared in this scope
   75 |     Option < core :: ops :: Range < i32 >> preedit_selection;
      |              ^~~~

Workaround by cleaning whitespace before matching the types.

…ghtly Rust

The C++ build started failling with nightly rust:
rust-lang/rust#125174 changed the output of
strignify! to contins more spaces between tokens, which we relied on to
perform some type substitution from Rust types to C++ types, resulting
in compilation errors:

```
build/api/cpp/generated_include/slint_builtin_structs_internal.h:71:5: error: ‘Option’ does not name a type
   71 |     Option < core :: ops :: Range < i32 >> replacement_range;
      |     ^~~~~~
build/api/cpp/generated_include/slint_builtin_structs_internal.h:75:14: error: ‘core’ was not declared in this scope
   75 |     Option < core :: ops :: Range < i32 >> preedit_selection;
      |              ^~~~
```

Workaround by cleaning whitespace before matching the types.
@ogoffart ogoffart merged commit ffbd8a6 into master Jun 15, 2024
36 checks passed
@ogoffart ogoffart deleted the olivier/fix-nightly-cpp branch June 15, 2024 12:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants