diff options
author | Nobel Singh <nobel2073@gmail.com> | 2023-12-05 18:12:29 +0545 |
---|---|---|
committer | Arthur Cohen <arthur.cohen@embecosm.com> | 2024-01-30 12:36:49 +0100 |
commit | f48f9a9ac6f20ffe2775437e3b21ed0208a9cee2 (patch) | |
tree | 8304a044d4e1f519beec5371df1335805ffe65c9 /gcc/c | |
parent | a7991de39ff3ef42cd48bb460a02134af73d7b9d (diff) | |
download | gcc-f48f9a9ac6f20ffe2775437e3b21ed0208a9cee2.zip gcc-f48f9a9ac6f20ffe2775437e3b21ed0208a9cee2.tar.gz gcc-f48f9a9ac6f20ffe2775437e3b21ed0208a9cee2.tar.bz2 |
gccrs: Generate error for const trait functions
Fixes issue #2040
Add check to assure that a function cant be declared const inside trait impl
blocks.
gcc/rust/ChangeLog:
* checks/errors/rust-ast-validation.cc (ASTValidation::visit): Add
check for const funtion.
gcc/testsuite/ChangeLog:
* rust/compile/issue-2040.rs: New test.
Signed-off-by: Nobel Singh <nobel2073@gmail.com>
Diffstat (limited to 'gcc/c')
0 files changed, 0 insertions, 0 deletions