Commit graph

29 commits

Author SHA1 Message Date
Olivier Goffart
aa7360a91a const-field-offset: Fix warnings on nightly rust
```
warning: non-local impl definition, they should be avoided as they go against expectation
```

Part of  #4706
2024-02-28 11:19:26 +01:00
Olivier Goffart
11dea135f7 Domain: slint-ui.com -> slint.dev 2023-06-16 10:55:08 +02:00
Tobias Hunger
4230ac2572
Update copyright information to reflect name change
Also run resue over the codebase and fix complaints from that tool.
2022-02-09 10:27:47 +01:00
Tobias Hunger
0063476aff Update license information
Use the reuse tool to get a better grip on licenses used in sixtyfps.
Fix a couple of licenses along the way.

* Uses creative commons for our own logo (commercial use!)
* Fixes some license information found in README files and documents
  them with proper .license files.
* Document Apache/MIT for helper_crates/const-field-offset which matches
  what its documentaion site says it uses.
* Add a list of licenses that apply to crates we publish and the tooling
  we have.

This patch only adds static information and does not contain any tooling
support.
2022-01-20 14:45:02 +01:00
Olivier Goffart
390b838c21 Use intra doc links in the documentation of vtable and const-field-offset macro 2021-11-09 17:37:31 +01:00
Olivier Goffart
4af34a8de1 const-field-offset: fix a bunch of clippy warnings in tests 2021-08-16 11:12:17 +02:00
Tobias Hunger
ad98137c17 Janitor: Mark up float comparisons where we want bitwise identity
Mark up test cases where we want bitwise identity of float values and
use `assert_eq!` since that produces better output in the error case.
2021-07-09 17:00:46 +02:00
Tobias Hunger
ac207428dc Janitor: CSpell fixes
Mark up some special words in documents (like C++ lingo in rust files).
2021-07-06 22:44:09 +02:00
Tobias Hunger
13d7f5e7bd Janitor: Fix typos in comments and user-facing strings
Also adapt tests for error messages containing the fixed strings.

No behavior change is intended!
2021-06-28 08:32:25 +02:00
Olivier Goffart
2a0c496e41 minor doc changes 2020-08-26 08:32:13 +02:00
Olivier Goffart
697aa61a0c Some doc polish 2020-08-25 15:33:15 +02:00
Olivier Goffart
c299bd5483 We are not using the ConstFieldOffset trait, so put it in a feature gate 2020-08-25 14:42:18 +02:00
Olivier Goffart
2c0fc29c5c Some fixup for the documentation 2020-08-25 14:42:18 +02:00
Olivier Goffart
304b0e7b0e Make sure the langref doc can be opened if the package is on crates.io
One need to make a symlink because the files need to be in the package
2020-08-25 14:42:18 +02:00
Olivier Goffart
cbeb982684 Use the FieldOffset struct from the upstream create 2020-08-24 11:20:38 +02:00
Simon Hausmann
b9bcf01019 Exclude const-field-offset from the license check
This is in fact a third-party crate slightly forked
2020-08-18 13:59:31 +02:00
Simon Hausmann
2823f32692 Apply license headers to all non-binary/non-json sources 2020-08-17 17:55:20 +02:00
Simon Hausmann
c7827c9dd5 Add support for Drop when using #[pin] with const_field_offset
A new attribute implements the Drop mechanics outlined in the Pin
documentation without requiring the use of unsafe on the caller side,
by means of an intermediate PinnedDrop trait.
2020-08-14 13:44:53 +02:00
Olivier Goffart
0a56912d0f Mouse grab in rust 2020-08-07 16:06:49 +02:00
Olivier Goffart
1bfd708784 Change the field_offsets() function to a FIELD_OFFSETS associated const 2020-08-03 16:04:55 +02:00
Olivier Goffart
40f4265071 Some improvement in ConstFieldOffset trait 2020-06-25 18:23:08 +02:00
Olivier Goffart
812b08b50c const_field_offset: Add compile type type for the offset
WIP
2020-06-25 17:46:29 +02:00
Olivier Goffart
f50a705e00 Add the #[pin] attribute to be able to project to the pinned item 2020-06-25 12:18:09 +02:00
Olivier Goffart
23e9397578 Add a Pinned flag to FieldOffset
So we can have Pinned projection
2020-06-25 12:18:09 +02:00
Olivier Goffart
d4e68971ef Make FieldOffset contra-variant in U 2020-06-24 18:53:53 +02:00
Olivier Goffart
68cea2aeec Fix soundness hole in FieldOffset
This was cause by the change to allow to create FieldOffset in const constext
because a Fn(T)->U  is not allowed in a const constext.
But we need to be contravariant in T.
2020-05-18 11:06:44 +02:00
Olivier Goffart
751a3fbe59 Work on const field offset crate to give type safe offsets 2020-05-18 11:06:44 +02:00
Olivier Goffart
7d1394e349 Add a viewer tool 2020-05-12 19:19:25 +02:00
Olivier Goffart
a0d9369336 Add a crate to compute the field offsets as const fn 2020-05-06 20:58:10 +02:00