Skip to content

Commit 30c21bd

Browse files
authored
Remove the unaligned_references lint (issue #323) (#328)
As of rust 1.69, the `unaligned_references` lint is depcreated as it's just built into the compiler. PL/Rust now uses rust 1.70, so we don't need it. Removing it eliminates a compliation warning on user functions too.
1 parent d1dd4da commit 30c21bd

File tree

4 files changed

+1
-9
lines changed

4 files changed

+1
-9
lines changed

doc/src/config-lints.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -74,12 +74,6 @@ https://doc.rust-lang.org/rustc/lints/listing/warn-by-default.html#suspicious-au
7474

7575
This defends against some patterns that can lead to soundness issues. These cases currently can only trigger in patterns which are otherwise blocked by the `unsafe_code` lint, but for better defense-in-depth, it's explicitly forbidden in PL/Rust.
7676

77-
### `unaligned_references`
78-
79-
https://doc.rust-lang.org/rustc/lints/listing/deny-by-default.html#unaligned-references
80-
81-
The unaligned_references lint detects unaligned references to fields of packed structs. This forbidden because it is a soundness hole in the language.
82-
8377
### `soft_unstable`
8478

8579
https://doc.rust-lang.org/rustc/lints/listing/deny-by-default.html#soft-unstable

doc/src/config-pg.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ purpose of the Lints.
158158
A comma-separated list of Rust lints to apply to every user function.
159159

160160
```bash
161-
plrust.compile_lints = 'plrust_extern_blocks, plrust_lifetime_parameterized_traits, implied_bounds_entailment, unsafe_code, plrust_filesystem_macros, plrust_env_macros, plrust_external_mod, plrust_fn_pointers, plrust_async, plrust_leaky, plrust_print_macros, plrust_stdio, unknown_lints, deprecated, suspicious_auto_trait_impls, unaligned_references, soft_unstable, plrust_autotrait_impls'
161+
plrust.compile_lints = 'plrust_extern_blocks, plrust_lifetime_parameterized_traits, implied_bounds_entailment, unsafe_code, plrust_filesystem_macros, plrust_env_macros, plrust_external_mod, plrust_fn_pointers, plrust_async, plrust_leaky, plrust_print_macros, plrust_stdio, unknown_lints, deprecated, suspicious_auto_trait_impls, soft_unstable, plrust_autotrait_impls'
162162
```
163163

164164

doc/src/functions/anatomy.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ mod forbidden {
3737
#![forbid(plrust_suspicious_trait_object)]
3838
#![forbid(soft_unstable)]
3939
#![forbid(suspicious_auto_trait_impls)]
40-
#![forbid(unaligned_references)]
4140
#![forbid(unsafe_code)]
4241
#![forbid(where_clauses_object_safety)]
4342

plrust/src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,6 @@ const DEFAULT_LINTS: &'static str = "\
9999
unsafe_code, \
100100
deprecated, \
101101
suspicious_auto_trait_impls, \
102-
unaligned_references, \
103102
where_clauses_object_safety, \
104103
soft_unstable\
105104
";

0 commit comments

Comments
 (0)