Commit Graph

250963 Commits

Author SHA1 Message Date
许杰友 Jieyou Xu (Joe)
12e999274d
Convert wasmtime check into a compiletest needs directive 2024-03-27 22:15:49 +00:00
许杰友 Jieyou Xu (Joe)
08853804d0
Use compiletest directives for properly only running wasm32-wasip1 tests on that target 2024-03-27 21:55:09 +00:00
许杰友 Jieyou Xu (Joe)
1dcbc23c4b
Accept only-wasm32-wasip1 directives 2024-03-27 21:43:40 +00:00
许杰友 Jieyou Xu (Joe)
7a99be35f2
Add FIXME to remind removing the check once all tests are ported over 2024-03-27 21:31:56 +00:00
许杰友 Jieyou Xu (Joe)
0f1bbe3141
Point out you can use --bless to update allow list for removed entries 2024-03-27 21:30:02 +00:00
Jules Bertholet
e931595909
Add rustfmt test for mut ref mut 2024-03-27 16:38:56 -04:00
bjorn3
4f0cde1e51 Define return type for functions in debuginfo 2024-03-27 20:36:49 +00:00
许杰友 Jieyou Xu (Joe)
50897170d5
Use a line-separated plain-text allowlist instead 2024-03-27 20:31:30 +00:00
bjorn3
0634aedbb7 Implement debug_type for tuples 2024-03-27 20:29:50 +00:00
bjorn3
55a2446a53 Don't panic when layout can't be computed and fix generation of array type debuginfo 2024-03-27 20:07:36 +00:00
许杰友 Jieyou Xu (Joe)
f10cf7bd85
Add run-make/link-framework/Makefile to allowlist 2024-03-27 20:02:43 +00:00
许杰友 Jieyou Xu (Joe)
81e3af7f4d
Rename expected_run_make_makefiles -> allowed_run_make_makefiles 2024-03-27 20:00:34 +00:00
许杰友 Jieyou Xu (Joe)
7cf69a8230
Pass tests_path and src_path separately 2024-03-27 20:00:34 +00:00
许杰友 Jieyou Xu (Joe)
ec25a425aa
Add comment for include!() usage 2024-03-27 20:00:34 +00:00
许杰友 Jieyou Xu (Joe)
f85063c1a8
Add tidy check to error on new Makefiles in tests/run-make 2024-03-27 20:00:33 +00:00
bors
c9f8f3438a Auto merge of #122396 - kornelski:vec-err-debloat, r=joboet
Less generic code for Vec allocations

Follow up to https://github.com/rust-lang/rust/pull/120504#issuecomment-1989826191 which hopefully makes compilation faster.
2024-03-27 19:58:44 +00:00
Nilstrieb
df4eec891d Let nils know about changes to target docs 2024-03-27 20:54:31 +01:00
Ramon de C Valle
0b860818e6 CFI: Fix drop and drop_in_place
Fix drop and drop_in_place by transforming self of drop and
drop_in_place methods into Drop trait objects.
2024-03-27 12:52:14 -07:00
bjorn3
fee1204ffa Stop taking FunctionCx's fn_abi field 2024-03-27 19:49:20 +00:00
bjorn3
69363cf9e7
Merge pull request #1472 from rust-lang/debuginfo_improvements2
Add debuginfo for statics
2024-03-27 19:22:09 +01:00
bors
0157da41ee Auto merge of #122460 - jieyouxu:rmake-example-refactor, r=Nilstrieb
Rework rmake support library API

### Take 1: Strongly-typed API

Context: https://github.com/rust-lang/rust/pull/122448#discussion_r1523774427

> My 2 cents: from my experience with writing similar "test DSLs", I would suggest to create these helpers as soon as possible in the process (basically the first time someone needs them, not only after N similar usages), and basically treat any imperative code in these high-level tests as a maintenance burden, basically making them as declarative as possible. Otherwise it might be a bit annoying to keep refactoring the tests later once such helpers are available.
>
> I would even discourage the arg method and create explicit methods for setting things like unpretty, the output file etc., but this might be more controversial, as it will make the invoked command-line arguments more opaque.

cc `@Kobzol` for the testing DSL suggestion.

Example:

```rs
let output = Rustc::new()
    .input_file("main.rs")
    .emit(&[EmitKind::Metadata])
    .extern_("stable", &stable_path)
    .output();
```

### Take 2: xshell-based macro API

Example:

```rs
let sh = Shell::new()?;
let stable_path = stable_path.to_string_lossy();
let output = cmd!(sh, "rustc main.rs --emit=metadata --extern stable={stable_path}").output()?;
```

### Take 3: Weakly-typed API with a few helper methods

```rs
let output = Rustc::new()
    .input("main.rs")
    .emit("metadata")
    .extern_("stable", &stable_path)
    .output();
```
2024-03-27 17:43:20 +00:00
Scott McMurray
336ff42367 num::NonZero::get can be 1 transmute instead of 3 2024-03-27 10:25:56 -07:00
bjorn3
4b80941ae3 Add debuginfo for statics
Most types are still unimplemented and get a placeholder byte array
instead.
2024-03-27 16:53:57 +00:00
bors
d5db7fb537 Auto merge of #123006 - compiler-errors:defer-suggestion-work, r=fee1-dead
Stop doing expensive work in `opt_suggest_box_span` eagerly

This PR defers the `can_coerce` and `predicate_must_hold_modulo_regions` calls in `opt_suggest_box_span`, and instead defers it until error reporting. This requires pulling the logic out of `note_obligation_cause_code` and into coercion, where we have access to the trait solver.

This also allows us to remove `TypeVariableOriginKind::OpaqueTypeInference`.
2024-03-27 15:29:00 +00:00
Kornel
443e29cd97 Less generic code for Vec allocations 2024-03-27 15:27:47 +00:00
Vagelis Prokopiou
cc4a1f42e6 Some wording improvement 2024-03-27 17:26:18 +02:00
Jules Bertholet
528d45af18
Feature gate 2024-03-27 11:20:28 -04:00
Kornel
826ddb3018 Suggest correct path in include_bytes! 2024-03-27 15:16:25 +00:00
bjorn3
f086e7abaf Allow debuginfo to reference global variables 2024-03-27 15:01:25 +00:00
Kornel
89ceced6f6 Helper function for resolve_path 2024-03-27 14:57:37 +00:00
xiaoxiangxianzi
3157114f0b chore: fix some comments
Signed-off-by: xiaoxiangxianzi <zhaoyizheng@outlook.com>
2024-03-27 22:32:53 +08:00
Oli Scherer
bd6a96f04e Int constants must be valtrees in pattern lowering 2024-03-27 14:28:50 +00:00
bjorn3
1f75f0fcad Move FileId caching to DebugContext::add_source_file 2024-03-27 14:14:30 +00:00
Michael Goulet
864e1fbc81 Remove TypeVariableOriginKind::OpaqueInference 2024-03-27 10:08:14 -04:00
Michael Goulet
2fe936f17d Stop doing expensive work in opt_suggest_box_span eagerly 2024-03-27 10:08:14 -04:00
bjorn3
68b59311fa
Merge pull request #1470 from rust-lang/debuginfo_improvements
Various small debuginfo improvements
2024-03-27 15:08:07 +01:00
Oli Scherer
d03df0a6b3 Add rustdoc hack 2024-03-27 14:02:17 +00:00
Oli Scherer
cf3ab41c83 Ensure no one re-adds Partial/Ord impls for DefId 2024-03-27 14:02:17 +00:00
Oli Scherer
5f4ac61ebd Remove DefId's Partial/Ord impls 2024-03-27 14:02:17 +00:00
Oli Scherer
e522d2906d Stop sorting DefIds in the compiler 2024-03-27 14:02:17 +00:00
Oli Scherer
5676326c72 Sort somem diagnostics by DefPathStr instead of DefId 2024-03-27 14:02:16 +00:00
Oli Scherer
6be79cb103 Sort a diagnostic by DefPathStr instead of DefId 2024-03-27 14:02:16 +00:00
Oli Scherer
57f68c3555 Sort method suggestions by DefPath instead of DefId 2024-03-27 14:02:16 +00:00
Oli Scherer
727807293b Don't sort DefIds in suggestions 2024-03-27 14:02:16 +00:00
Oli Scherer
150a5e5f92 Do not sort DefIds in diagnostics 2024-03-27 14:02:16 +00:00
Oli Scherer
28363ea4eb Remove Partial/Ord from EarlyParamRegion 2024-03-27 14:02:16 +00:00
Oli Scherer
1d662c9eee Remove Partial/Ord from AdtDef 2024-03-27 14:02:16 +00:00
Oli Scherer
459ea32a27 Remove Partial/Ord from BoundRegion 2024-03-27 14:02:16 +00:00
Oli Scherer
e87d10846e Remove Ord from BoundTy 2024-03-27 14:02:16 +00:00
Oli Scherer
dd9fe01d06 Remove Ord from Binder 2024-03-27 14:02:16 +00:00