Commit graph

30 commits

Author SHA1 Message Date
Lukas Wirth
abe249559d internal: Give ConstBlockId and InTypeConstId named Location types 2023-06-12 18:21:17 +02:00
hkalbasi
a4695788ca Add a bunch of fixme comments 2023-06-12 00:37:11 +03:30
hkalbasi
a481e004b0 Lower const params with a bad id 2023-06-11 00:39:28 +03:30
hkalbasi
51368793b4 MIR episode 6 2023-05-28 23:25:15 +03:30
hkalbasi
cbcafd3539 MIR episode 5 2023-05-12 18:17:15 +03:30
hkalbasi
aafe9b1e06 Lazy evaluate consts in path_to_const 2023-05-05 01:17:11 +03:30
hkalbasi
6312fbf521 MIR episode 4 2023-05-01 23:23:10 +03:30
Lukas Wirth
99b69525f4 hir_def::expr -> hir_def::hir, hir_def::type_ref -> hir_def::hir::type_ref 2023-04-06 19:36:25 +02:00
hkalbasi
8a3ad7c3d5 Support evaluating inherent associated constants with generics 2023-03-21 02:20:30 +03:30
hkalbasi
b7b9ae59a0 desugar ? operator 2023-03-17 13:08:35 +03:30
hkalbasi
71e1c025f8 Revert #14285 2023-03-10 11:57:30 +03:30
hkalbasi
cf47c15821 Evaluate consts in path_to_const 2023-03-08 16:42:20 +03:30
hkalbasi
cd67589f63 beginning of MIR 2023-02-27 23:45:54 +03:30
Daniel Eades
bb083b8202 remove useless casts 2023-01-02 15:02:54 +00:00
Daniel Eades
4f8ffd0ba4 remove unnecessary lifetimes that can be elided 2023-01-02 15:02:54 +00:00
Daniel Eades
ed128872eb remove needless borrows 2023-01-02 14:52:32 +00:00
Yuri Astrakhan
e16c76e3c3 Inline all format arguments where possible
This makes code more readale and concise,
moving all format arguments like `format!("{}", foo)`
into the more compact `format!("{foo}")` form.

The change was automatically created with, so there are far less change
of an accidental typo.

```
cargo clippy --fix -- -A clippy::all -W clippy::uninlined_format_args
```
2022-12-24 14:36:10 -05:00
Florian Diebold
d3cb032f7e Make assoc_resolutions always have a Substitution 2022-12-10 17:05:33 +01:00
bvanjoi
7012b50db5 feat: resolve const for trait impls(close #13694) 2022-12-10 20:06:25 +08:00
Lukas Wirth
6d0d051628 Simplify 2022-09-20 17:12:10 +02:00
OleStrohm
5313bd1984 Cleaned up code based on feedback 2022-09-12 20:20:45 +01:00
OleStrohm
301b8894ea Added more consteval tests and fixed consteval result 2022-09-12 20:20:45 +01:00
OleStrohm
ad0a6bf1a3 Added consteval tests 2022-09-12 20:20:43 +01:00
OleStrohm
2f84b6e2e5 Almost there 2022-09-12 20:20:22 +01:00
OleStrohm
e28046c673 Removed unnecessary TODO 2022-09-12 20:19:19 +01:00
OleStrohm
997fc46efa Implemented basic enum const eval 2022-09-12 20:19:13 +01:00
KaDiWa
232176b46a
remove imports that are also in edition 2021's prelude 2022-08-09 01:16:32 +02:00
Artur Sinila
83177a7cfe
fix: address suggestions 2022-07-17 18:22:11 +03:00
Artur Sinila
a96f0aa7cd
feat: support negative const generic parameters
* feat: support `bool` & `char` const generics
2022-07-17 04:18:53 +03:00
Peh
1f011fa4a3 style: rename crates to kebab case 2022-05-01 10:48:58 +00:00
Renamed from crates/hir_ty/src/consteval.rs (Browse further)