The segfaults happens in:
```
ExpressionSemanticVisitor::visit(PtrExp*) (this=0x7fffffff69d8, exp=0x7fffeb62d720) at src/dmd/expressionsem.d:7442
7442 Type tb = exp.e1.type.toBasetype();
(gdb) bt
#0 ExpressionSemanticVisitor::visit(PtrExp*) (this=0x7fffffff69d8, exp=0x7fffeb62d720) at src/dmd/expressionsem.d:7442
#1 0x00005555559b66b6 in PtrExp::accept(Visitor*) (this=0x7fffeb62d720, v=0x7fffffff69d8) at src/dmd/expression.d:5481
```
The PtrExp in question comes from this line:
source/mud/memory/smartpointers.d:179
```
assert(!__traits(compiles, *classPtr));
```
I'm looking into reducing it
Comment #2 by dkorpel — 2023-06-08T13:23:11Z
Reduced to:
```D
class A {}
void h()
{
const auto classPtr = SPtr.init;
assert(!__traits(compiles, *classPtr));
}
struct SPtr
{
A ptr() { return A.init; }
alias ptr this;
}
```
Comment #3 by dlang-bot — 2023-06-08T14:22:36Z
@dkorpel created dlang/dmd pull request #15300 "Fix 23979 - ICE on failed alias this attempt on pointer expression" fixing this issue:
- Fix 23979 - ICE on failed alias this attempt on pointer expression
https://github.com/dlang/dmd/pull/15300
Comment #4 by dlang-bot — 2023-06-10T17:33:00Z
dlang/dmd pull request #15300 "Fix 23979 - ICE on failed alias this attempt on pointer expression" was merged into stable:
- 8e92e709dc1796c163fb979fa0a91783eeb8c902 by Dennis Korpel:
Fix 23979 - ICE on failed alias this attempt on pointer expression
https://github.com/dlang/dmd/pull/15300
Comment #5 by dlang-bot — 2023-06-16T09:07:50Z
dlang/dmd pull request #15325 "merge stable" was merged into master:
- 5e1833a279a8a72f0de0532530cfad832d3ed980 by Dennis:
Fix 23979 - ICE on failed alias this attempt on pointer expression (#15300)
https://github.com/dlang/dmd/pull/15325
Comment #6 by dlang-bot — 2023-06-16T09:07:56Z
dlang/dmd pull request #15310 "Merge stable" was merged into master:
- 5e1833a279a8a72f0de0532530cfad832d3ed980 by Dennis:
Fix 23979 - ICE on failed alias this attempt on pointer expression (#15300)
https://github.com/dlang/dmd/pull/15310