Skip to content

Commit

Permalink
Fix changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
ntrel committed Dec 7, 2024
1 parent a80d302 commit 1b025ab
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion changelog/dmd.shortened-method-constructor.dd
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,12 @@ struct Number
{
int x;

this(int x) => this.x = x;
void vf(int);
this(int x) => vf(x);
this(float x) => this(cast(int) x);
}
---

The expression body must be a `this`/`super` call or have type `void`.

Postblits and destructors already supported shortened method syntax because they return `void`.

0 comments on commit 1b025ab

Please sign in to comment.