Skip to content

Commit

Permalink
Sema: rewrite peer type resolution
Browse files Browse the repository at this point in the history
The existing logic for peer type resolution was quite convoluted and
buggy. This rewrite makes it much more resilient, readable, and
extensible. The algorithm works by first iterating over the types to
select a "strategy", then applying that strategy, possibly applying peer
resolution recursively.

The new semantics around PTR for comptime-known fixed-width integers did
require some small changes to parts of the compiler, std, and
compiler_rt. Regarding the MachO changes, I spoke to @kubkon about how
best to do them, and this is what he suggested.

Several new tests have been added to cover cases which the old logic did
not correctly handle.

Resolves: #15644
Resolves: #15693
Resolves: #15709
  • Loading branch information
mlugg committed May 20, 2023
1 parent 7621e56 commit cfdf532
Show file tree
Hide file tree
Showing 4 changed files with 1,350 additions and 544 deletions.
Loading

0 comments on commit cfdf532

Please sign in to comment.