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

compiletest: Make diagnostic kind mandatory on line annotations (take 2) #139720

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

petrochenkov
Copy link
Contributor

Compiletest currently accepts line annotations without kind in UI tests.

    let a = b + c; //~ my message

Such annotations have two effects.

  • First, they match any compiler-produced diagnostic kind. This functionality is never used in practice, there are no target-dependent diagnostic kinds of something like that.
  • Second, they are not "viral". For example, any explicit //~ NOTE my msg in a test requires all other NOTE diagnostics in the same test to be annotated. Implicit //~ my msg will just match the note and won't require other annotations.

The second functionality has a replacement since recently - directive //@ dont-require-annotations: NOTE.

This PR removes support for //~ my message and makes the explicit diagnostic kind mandatory.
Unwanted additional annotations are suppressed using the dont-require-annotations directive.

Previous attempt - #139427.
r? @jieyouxu

@rustbot rustbot added A-compiletest Area: The compiletest test runner A-testsuite Area: The testsuite used to check the correctness of rustc S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Apr 12, 2025
@petrochenkov
Copy link
Contributor Author

MCP: rust-lang/compiler-team#862, waiting on compiler team.

@petrochenkov petrochenkov added S-waiting-on-team Status: Awaiting decision from the relevant subteam (see the T-<team> label). I-compiler-nominated Nominated for discussion during a compiler team meeting. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 12, 2025
@petrochenkov
Copy link
Contributor Author

Most of the diff is due to updated .stderr files.
Technically I could add the //@ dont-require-annotations: NOTE directives to file ends to avoid this, but it really goes against the usual style.

@rustbot
Copy link
Collaborator

rustbot commented Apr 12, 2025

Some changes occurred in src/tools/compiletest

cc @jieyouxu

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-llvm-19 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
#19 exporting to docker image format
#19 sending tarball 19.8s done
#19 DONE 27.0s
##[endgroup]
Setting extra environment values for docker:  --env ENABLE_GCC_CODEGEN=1 --env GCC_EXEC_PREFIX=/usr/lib/gcc/
[CI_JOB_NAME=x86_64-gnu-llvm-19]
[CI_JOB_NAME=x86_64-gnu-llvm-19]
debug: `DISABLE_CI_RUSTC_IF_INCOMPATIBLE` configured.
---
sccache: Listening on address 127.0.0.1:4226
##[group]Configure the build
configure: processing command line
configure: 
configure: build.configure-args := ['--build=x86_64-unknown-linux-gnu', '--llvm-root=/usr/lib/llvm-19', '--enable-llvm-link-shared', '--set', 'rust.randomize-layout=true', '--set', 'rust.thin-lto-import-instr-limit=10', '--set', 'build.print-step-timings', '--enable-verbose-tests', '--set', 'build.metrics', '--enable-verbose-configure', '--enable-sccache', '--disable-manage-submodules', '--enable-locked-deps', '--enable-cargo-native-static', '--set', 'rust.codegen-units-std=1', '--set', 'dist.compression-profile=balanced', '--dist-compression-formats=xz', '--set', 'rust.lld=false', '--disable-dist-src', '--release-channel=nightly', '--enable-debug-assertions', '--enable-overflow-checks', '--enable-llvm-assertions', '--set', 'rust.verify-llvm-ir', '--set', 'rust.codegen-backends=llvm,cranelift,gcc', '--set', 'llvm.static-libstdcpp', '--enable-new-symbol-mangling']
configure: build.build          := x86_64-unknown-linux-gnu
configure: target.x86_64-unknown-linux-gnu.llvm-config := /usr/lib/llvm-19/bin/llvm-config
configure: llvm.link-shared     := True
configure: rust.randomize-layout := True
configure: rust.thin-lto-import-instr-limit := 10
---
  Number of decisions:   4447
  longest path:          1159 (code:    152)
  longest backtrack:       66 (code:    428)
Shared 86733 out of 152951 states by creating 14756 new states, saving 71977
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/expmed.cc: In function ‘rtx_def* extract_bit_field_1(rtx, poly_uint64, poly_uint64, int, rtx, machine_mode, machine_mode, bool, bool, rtx_def**)’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/expmed.cc:1864:45: warning: ‘*(unsigned int*)((char*)&imode + offsetof(scalar_int_mode, scalar_int_mode::m_mode))’ may be used uninitialized [-Wmaybe-uninitialized]
 1864 |       rtx sub = extract_bit_field_as_subreg (mode1, op0, imode,
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
 1865 |                                              bitsize, bitnum);
      |                                              ~~~~~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/expmed.cc:1824:19: note: ‘*(unsigned int*)((char*)&imode + offsetof(scalar_int_mode, scalar_int_mode::m_mode))’ was declared here
 1824 |   scalar_int_mode imode;
      |                   ^~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/gimple-range-gori.cc: In member function ‘void range_def_chain::dump(FILE*, basic_block, const char*)’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/gimple-range-gori.cc:319:19: warning: format not a string literal and no format arguments [-Wformat-security]
  319 |           fprintf (f, prefix);
      |           ~~~~~~~~^~~~~~~~~~~
---
                 from /checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/analyzer/region-model.h:33,
                 from /checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/analyzer/access-diagram.cc:39:
In constructor ‘ana::byte_range::byte_range(ana::byte_offset_t, ana::byte_size_t)’,
    inlined from ‘virtual text_art::table ana::string_literal_spatial_item::make_table(const ana::bit_to_table_map&, text_art::style_manager&) const’ at /checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/analyzer/access-diagram.cc:1812:18:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/analyzer/store.h:312:5: warning: ‘size_in_bytes.generic_wide_int<fixed_wide_int_storage<128> >::fixed_wide_int_storage<128>.fixed_wide_int_storage<128>::val[1]’ may be used uninitialized [-Wmaybe-uninitialized]
  312 |     m_size_in_bytes (size_in_bytes)
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/analyzer/access-diagram.cc: In member function ‘virtual text_art::table ana::string_literal_spatial_item::make_table(const ana::bit_to_table_map&, text_art::style_manager&) const’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/analyzer/access-diagram.cc:1808:28: note: ‘size_in_bytes.generic_wide_int<fixed_wide_int_storage<128> >::fixed_wide_int_storage<128>.fixed_wide_int_storage<128>::val[1]’ was declared here
 1808 |                byte_size_t size_in_bytes
      |                            ^~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/diagnostic.cc: In function ‘void fancy_abort(const char*, int, const char*)’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/diagnostic.cc:1677:15: warning: format not a string literal and no format arguments [-Wformat-security]
 1677 |       fnotice (stderr, diagnostic_kind_text[DK_ICE]);
---
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/gcc.cc:7930:9: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
 7930 |   write (fd, "\n\n", 2);
      |   ~~~~~~^~~~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/gcc.cc: In member function ‘void driver::final_actions() const’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/gcc.cc:9307:13: warning: ignoring return value of ‘int truncate(const char*, __off_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
 9307 |     truncate(totruncate_file, 0);
      |     ~~~~~~~~^~~~~~~~~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/lto-wrapper.cc: In function ‘bool find_and_merge_options(int, off_t, const char*, vec<cl_decoded_option>, bool, vec<cl_decoded_option>*, const char*)’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/lto-wrapper.cc:1165:8: warning: ignoring return value of ‘ssize_t read(int, void*, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
 1165 |   read (fd, data, length);
      |   ~~~~~^~~~~~~~~~~~~~~~~~
---
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/lto/lto-common.cc: In function ‘void lto_resolution_read(splay_tree, FILE*, lto_file*)’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/lto/lto-common.cc:2091:10: warning: ignoring return value of ‘int fscanf(FILE*, const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
 2091 |   fscanf (resolution, " ");   /* Read white space.  */
      |   ~~~~~~~^~~~~~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/lto/lto-common.cc:2093:9: warning: ignoring return value of ‘size_t fread(void*, size_t, size_t, FILE*)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
 2093 |   fread (obj_name, sizeof (char), name_len, resolution);
      |   ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/lto/lto-common.cc:2113:10: warning: ignoring return value of ‘int fscanf(FILE*, const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
 2113 |   fscanf (resolution, "%u", &num_symbols);
      |   ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/gcc/jit/jit-recording.cc:32:
---
Applying io_quotes_use            to linux/blkzoned.h
Applying io_quotes_use            to linux/ipmi.h
Applying io_quotes_use            to linux/psp-dbc.h
Applying io_quotes_use            to linux/bt-bmc.h
Applying io_quotes_use            to linux/tps6594_pfsm.h
Applying io_quotes_use            to linux/cxl_mem.h
Applying io_quotes_use            to linux/wmi.h
Applying io_quotes_use            to linux/auto_fs.h
Applying io_quotes_use            to linux/mmtimer.h
Applying io_quotes_use            to linux/f2fs.h
Applying io_quotes_use            to linux/vhost.h
---
Applying io_quotes_use            to sound/asound.h
Applying io_quotes_use            to sound/compress_offload.h
Applying hpux8_bogus_inlines      to math.h
Applying pthread_incomplete_struct_argument to pthread.h
Fixed:  pthread.h
Applying io_quotes_use            to misc/mrvl_cn10k_dpi.h
Applying io_quotes_use            to misc/ocxl.h
Applying io_quotes_use            to misc/cxl.h
Applying io_quotes_use            to misc/xilinx_sdfec.h
Applying io_quotes_def            to unicode/platform.h
Applying sun_malloc               to malloc.h
Applying io_quotes_use            to scsi/cxlflash_ioctl.h
---
Applying machine_name             to x86_64-linux-gnu/bits/unistd_ext.h
Applying io_quotes_use            to x86_64-linux-gnu/asm/mtrr.h
Applying io_quotes_use            to x86_64-linux-gnu/asm/amd_hsmp.h
Applying machine_name             to openssl/e_os2.h
Applying io_quotes_use            to drm/xe_drm.h
Applying io_quotes_use            to drm/radeon_drm.h
Applying io_quotes_use            to drm/panfrost_drm.h
Applying io_quotes_use            to drm/etnaviv_drm.h
Applying io_quotes_use            to drm/lima_drm.h
Applying io_quotes_use            to drm/qaic_accel.h
Applying io_quotes_use            to drm/vc4_drm.h
Applying io_quotes_use            to drm/i915_drm.h
Applying io_quotes_use            to drm/omap_drm.h
Applying io_quotes_use            to drm/pvr_drm.h
Applying io_quotes_use            to drm/amdgpu_drm.h
Applying io_quotes_use            to drm/vgem_drm.h
Applying io_quotes_use            to drm/msm_drm.h
Applying io_quotes_use            to drm/v3d_drm.h
Applying io_quotes_use            to drm/exynos_drm.h
Applying io_quotes_use            to drm/nouveau_drm.h
Applying io_quotes_use            to drm/drm.h
Applying io_quotes_use            to drm/habanalabs_accel.h
Applying io_quotes_use            to drm/tegra_drm.h
Applying io_quotes_use            to rdma/rdma_user_ioctl.h
cc1: note: self-tests are not enabled in this build
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/c++tools/server.cc: In function ‘void server(bool, int, module_resolver*)’:
/checkout/obj/build/x86_64-unknown-linux-gnu/gcc/src/c++tools/server.cc:620:10: warning: ignoring return value of ‘int pipe(int*)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
---
failures:

---- [codegen-units] tests/codegen-units/item-collection/asm-sym.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/asm-sym.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

---- [codegen-units] tests/codegen-units/item-collection/generic-functions.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/generic-functions.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/closures.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/closures.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/generic-impl.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/generic-impl.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/impl-in-non-instantiated-generic.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/impl-in-non-instantiated-generic.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/items-within-generic-items.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/items-within-generic-items.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/implicit-panic-call.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/implicit-panic-call.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/function-as-argument.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/function-as-argument.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/drop-glue-eager.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/drop-glue-eager.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/generic-drop-glue.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/generic-drop-glue.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/instantiation-through-vtable.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/instantiation-through-vtable.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/non-generic-closures.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/non-generic-closures.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/drop_in_place_intrinsic.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/drop_in_place_intrinsic.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/non-generic-functions.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/non-generic-functions.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/static-init.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/static-init.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/statics-and-consts.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/statics-and-consts.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/unreferenced-const-fn.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/unreferenced-const-fn.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/non-generic-drop-glue.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/non-generic-drop-glue.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/cross-crate-trait-method.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/cross-crate-trait-method.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/trait-method-as-argument.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/trait-method-as-argument.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/transitive-drop-glue.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/transitive-drop-glue.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/trait-method-default-impl.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/trait-method-default-impl.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/trait-implementations.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/trait-implementations.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/overloaded-operators.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/overloaded-operators.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/cross-crate-generic-functions.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/cross-crate-generic-functions.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/tuple-drop-glue.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/tuple-drop-glue.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/cross-crate-closures.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/cross-crate-closures.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/unsizing.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/unsizing.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/item-collection/unused-traits-and-generics.rs stdout ----

thread '[codegen-units] tests/codegen-units/item-collection/unused-traits-and-generics.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/incremental-merging.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/incremental-merging.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/inline-always.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/inline-always.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/local-transitive-inlining.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/local-transitive-inlining.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/local-generic.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/local-generic.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/regular-modules.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/regular-modules.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/statics.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/statics.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/local-drop-glue.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/local-drop-glue.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/methods-are-with-self-type.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/methods-are-with-self-type.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/vtable-through-const.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/vtable-through-const.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/extern-generic.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/extern-generic.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/inlining-from-extern-crate.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/inlining-from-extern-crate.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/extern-drop-glue.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/extern-drop-glue.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`

---- [codegen-units] tests/codegen-units/partitioning/shared-generics.rs stdout ----

thread '[codegen-units] tests/codegen-units/partitioning/shared-generics.rs' panicked at src/tools/compiletest/src/errors.rs:40:18:
unexpected diagnostic kind `MONO`, expected `ERROR`, `WARN`, `NOTE`, `HELP` or `SUGGESTION`


failures:
    [codegen-units] tests/codegen-units/item-collection/asm-sym.rs
    [codegen-units] tests/codegen-units/item-collection/generic-functions.rs

Copy link
Member

@RalfJung RalfJung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

const ui tets changes LGTM, except that the PR also removes some colons which caught me by surprise as it wasn't mentioned... but if we will unify the colon vs no-colon style soon anyway, it doesn't really matter.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There you also changed the annotation style for no apparent reason?

#![allow(static_mut_refs)]

fn invalid() {
static S: i8 = 10;

const C: &bool = unsafe { std::mem::transmute(&S) };
//~^ERROR: undefined behavior
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More removed colons.

@petrochenkov
Copy link
Contributor Author

petrochenkov commented Apr 13, 2025

the PR also removes some colons which caught me by surprise as it wasn't mentioned

This is accidental, this PR was converted from #139427 which had some colon changes, and I tried to revert all of them, but apparently missed some. If some more are found during review I'll revert them too.

@bors
Copy link
Collaborator

bors commented Apr 13, 2025

☔ The latest upstream changes (presumably #139746) made this pull request unmergeable. Please resolve the merge conflicts.

@tshepang
Copy link
Member

would be nice if this also updated rustc-dev-guide

@petrochenkov
Copy link
Contributor Author

would be nice if this also updated rustc-dev-guide

I'll update, I was waiting for #139618 to land first.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-compiletest Area: The compiletest test runner A-testsuite Area: The testsuite used to check the correctness of rustc I-compiler-nominated Nominated for discussion during a compiler team meeting. S-waiting-on-team Status: Awaiting decision from the relevant subteam (see the T-<team> label). T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants