2,420 matches across 25 files for error lang:Markdown
snippet_mode: grep · sorted by relevance
1---
2▶name: Internal Compiler Error
3about: Create a report for an internal compiler error in rustc.
4labels: C-bug, I-ICE, T-compiler
· · ·
3▶about: Create a report for an internal compiler error in rustc.
4labels: C-bug, I-ICE, T-compiler
5title: "[ICE]: "
· · ·
6---
7<!--
8▶Thank you for finding an Internal Compiler Error! 🧊 If possible, try to provide
9a minimal verifiable example. You can read "Rust Bug Minimization Patterns" for
10how to create smaller examples.
· · ·
30```
31
32▶### Error output
33
34```
15-->
16
17▶This is the **tracking issue** for the `YOUR_LINT_NAME_HERE` future-compatibility warning and other related errors. The goal of this page is to describe why this change was made and how you can fix code that is affected by it. It also provides a place to ask questions or register a complaint if you feel the change should not be made. For more information on the policy around future-compatibility warnings, see our [breaking change policy guidelines][guidelines].
18
19[guidelines]: https://rustc-dev-guide.rust-lang.org/bug-fix-procedure.html
· · ·
37*Give some recommendations on how a user can avoid the lint.*
38
39▶### When will this warning become a hard error?
40
41*If known, describe the future plans. For example, how long you anticipate this being a warning, or if there are other factors that will influence the anticipated closure.*
· · ·
46- [ ] Raise lint level to deny
47- [ ] Change the lint to report in dependencies
48▶- [ ] Switch to a hard error
49
50### Implementation history
226the instructions in step 2 to get them on PATH.
227
228▶Using Windows native Python can be helpful if you get errors when building LLVM.
229You may also want to use Git for Windows, as it is often *much* faster. Turning
230off real-time protection in the Windows Virus & Threat protections settings can
110-------------------
111- [Array coercions may now result in less inference constraints than before](https://github.com/rust-lang/rust/pull/140283)
112▶- Importing `$crate` without renaming, i.e. `use $crate::{self};`, is now no longer permitted due to stricter error checking for `self` imports.
113- [const-eval: be more consistent in the behavior of padding during typed copies.](https://github.com/rust-lang/rust/pull/148967)
114 In very rare cases, this may cause compilation errors due to bytes from parts of a pointer ending up in the padding bytes of a `const` or `static`.
· · ·
114▶ In very rare cases, this may cause compilation errors due to bytes from parts of a pointer ending up in the padding bytes of a `const` or `static`.
115- [A future-incompatibility warning lint `ambiguous_glob_imported_traits` is now reported when using an ambiguously glob imported trait](https://github.com/rust-lang/rust/pull/149058)
116- [Check lifetime bounds of types mentioning only type parameters](https://github.com/rust-lang/rust/pull/149389)
· · ·
117▶- [Report more visibility-related ambiguous import errors](https://github.com/rust-lang/rust/pull/149596)
118- [Deprecate `Eq::assert_receiver_is_total_eq` and emit future compatibility warnings on manual impls](https://github.com/rust-lang/rust/pull/149978)
119- [powerpc64: Use the ELF ABI version set in target spec instead of guessing](https://github.com/rust-lang/rust/pull/150468) (fixes the ELF ABI used by the OpenBSD target)
· · ·
161- [Add warn-by-default `unused_visibilities` lint for visibility on `const _` declarations](https://github.com/rust-lang/rust/pull/147136)
162- [Update to Unicode 17](https://github.com/rust-lang/rust/pull/148321)
163▶- [Avoid incorrect lifetime errors for closures](https://github.com/rust-lang/rust/pull/148329)
164
165<a id="1.94.0-Platform-Support"></a>
· · ·
232 Some finer details of how precise closure captures get affected by pattern matching have been changed. In some cases, this can cause a non-move closure that was previously capturing an entire variable by move, to now capture only part of that variable by move, and other parts by borrow. This can cause the borrow checker to complain where it previously didn't, or cause `Drop` to run at a different point in time.
233- [Standard library macros are now imported via prelude, not via injected `#[macro_use]`](https://github.com/rust-lang/rust/pull/139493)
234▶ This will raise an error if macros of the same name are glob imported.
235 For example if a crate defines their own `matches` macro and then glob imports that,
236 it's now ambiguous whether the custom or standard library `matches` is meant and
+ 364 more matches in this file
112(15:53:08) bjorn3: already using DW_AT_ranges for DW_TAG_compilation_unit
113(15:53:19) bjorn3: for individual functions, there are no gaps
114▶(15:57:07) bjorn3: still the same error with DW_AT_low_pc and DW_AT_high_pc
115(15:57:24) bjorn3: tromey: ^
116(15:58:08) tromey: hmmm
121- [GCC Internals Documentation](https://gcc.gnu.org/onlinedocs/gccint/)
122- Project-specific documentation in the `doc/` directory:
123▶ - [Common errors](doc/errors.md)
124 - [Debugging](doc/debugging.md)
125 - [Debugging libgccjit](doc/debugging-libgccjit.md)
176More specific documentation is available in the [`doc`](./doc) folder:
177
178▶ * [Common errors](./doc/errors.md)
179 * [Debugging GCC LTO](./doc/debugging-gcc-lto.md)
180 * [Debugging libgccjit](./doc/debugging-libgccjit.md)
1# Debugging libgccjit
2
3▶Sometimes, libgccjit will crash and output an error like this:
4
5```
· · ·
6during RTL pass: expand
7▶libgccjit.so: error: in expmed_mode_index, at expmed.h:249
80x7f0da2e61a35 expmed_mode_index
9 ../../../gcc/gcc/expmed.h:249
· · ·
28```
29
30▶To see the code which causes this error, call the following function:
31
32```c
· · ·
38
39```
40▶libgccjit.so: /tmp/something.c:61322:0: error: in expmed_mode_index, at expmed.h:249
41```
42
· · ·
43▶Or add a breakpoint to `add_error` in gdb and print the line number using:
44
45```
1▶# Common errors
2
3This file lists errors that were encountered and how to fix them.
· · ·
3▶This file lists errors that were encountered and how to fix them.
4
5### `failed to build archive` error
· · ·
5▶### `failed to build archive` error
6
7When you get this error:
· · ·
7▶When you get this error:
8
9```
· · ·
10▶error: failed to build archive: failed to open object file: No such file or directory (os error 2)
11```
12
+ 2 more matches in this file
25```
26
27▶When there is no more errors, generate the git patch:
28
29```bash
· · ·
37```
38
39▶When you have no more errors, you can send the `.patch` file to GCC by sending an
40email to `gcc-patches@gcc.gnu.org` and to the relevant GCC mailing lists
41depending on what your patch changes. You can find the list of the mailing lists
1▶#### Note: this error code is no longer emitted by the compiler.
2
3This error suggests that the expression arm corresponding to the noted pattern
· · ·
3▶This error suggests that the expression arm corresponding to the noted pattern
4will never be reached as for all possible values of the expression being
5matched, one of the preceding patterns will match.
1▶#### Note: this error code is no longer emitted by the compiler.
2
3This error indicates that an empty match expression is invalid because the type
· · ·
3▶This error indicates that an empty match expression is invalid because the type
4it is matching on is non-empty (there exist values of this type). In safe code
5it is impossible to create an instance of an empty type, so empty match
· · ·
6▶expressions are almost never desired. This error is typically fixed by adding
7one or more cases to the match expression.
8
1▶This error indicates that the compiler cannot guarantee a matching pattern for
2one or more possible inputs to a match expression. Guaranteed matches are
3required in order to assign values to match expressions, or alternatively,
· · ·
14let x = Terminator::HastaLaVistaBaby;
15
16▶match x { // error: non-exhaustive patterns: `HastaLaVistaBaby` not covered
17 Terminator::TalkToMyHand => {}
18}
· · ·
19```
20
21▶If you encounter this error you must alter your patterns so that every possible
22value of the input type is matched. For types with a small number of variants
23(like enums) you should probably cover all cases explicitly. Alternatively, the
1▶#### Note: this error code is no longer emitted by the compiler.
2
3This error indicates that the bindings in a match arm would require a value to
· · ·
3▶This error indicates that the bindings in a match arm would require a value to
4be moved into more than one location, thus violating unique ownership. Code
5like the following is invalid as it requires the entire `Option<String>` to be
· · ·
15
16match x {
17▶ op_string @ Some(s) => {}, // error: use of moved value
18 None => {},
19}
· · ·
20```
21
22▶See also the error E0303.
23
1▶#### Note: this error code is no longer emitted by the compiler.
2
3In a pattern, all values that don't implement the `Copy` trait have to be bound
· · ·
16let x = Some((X { x: () }, X { x: () }));
17match x {
18▶ Some((y, ref z)) => {}, // error: cannot bind by-move and by-ref in the
19 // same pattern
20 None => panic!()
1▶#### Note: this error code is no longer emitted by the compiler.
2
3Constants can only be initialized by a constant value or, in a future
· · ·
4▶version of Rust, a call to a const function. This error indicates the use
5of a path (like a::b, or x) denoting something other than one of these
6allowed items.
8}
9
10▶// error: cannot call non-const function `create_some` in constants
11const FOO: Option<u8> = create_some();
12```
· · ·
15be marked `const`.
16
17▶To fix this error, you can declare `create_some` as a constant function:
18
19```
· · ·
23}
24
25▶const FOO: Option<u8> = create_some(); // no error!
26```
27
13
14 let Foo { a: x, a: y } = x;
15▶ // error: field `a` bound multiple times in the pattern
16}
17```
· · ·
18
19Each occurrence of a field name binds the value of that field, so to fix this
20▶error you will have to remove or alter the duplicate uses of the field name.
21Perhaps you misspelled another field name? Example:
22