You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[DIP 1043---Shortened Method Syntax](https://forum.dlang.org/thread/ahswpyijfidyorixgaqm@forum.dlang.org) has been accepted, the flag `-preview=shortenedMethods`
405
+
is no longer required to write shortened function bodies:
406
+
)
407
+
408
+
---
409
+
int add(int x, int y) pure => x + y;
410
+
411
+
// equivalent full function body:
412
+
int add(int x, int y) pure
413
+
{
414
+
return x + y;
415
+
}
416
+
---
417
+
418
+
$(P
419
+
The preview flag will still work until it is deprecated in a future release.
420
+
)
421
+
)
422
+
400
423
401
424
)
402
425
@@ -1011,6 +1034,7 @@ $(LI $(BUGZILLA 23355): invalid template parameter loses error location in some
1011
1034
$(LI $(BUGZILLA 23357): ImportC: compatible types with definitions leads to redeclaration error when used from D.)
1012
1035
$(LI $(BUGZILLA 23379): Cast of expressions with type noreturn result in ice)
1013
1036
$(LI $(BUGZILLA 23380): [dip1000] class parameter should not be treated as ref qua lifetime)
1037
+
$(LI $(BUGZILLA 23406): [seg fault] enums can cause compile time seg faults with assignments using alias this)
0 commit comments