On Wednesday, 4 April 2018 at 08:08:40 UTC, Dejan Lekic wrote:
On Sunday, 1 April 2018 at 15:54:16 UTC, Steven Schveighoffer wrote:
I currently have a situation where I want to have a function that accepts a parameter optionally.

This is what function overloading and/or default values are for, right?

Not if you'd like to pass an actual _optional_ parameter for e.g. an int.
Default parameter would actually assign a value.

See also:
https://forum.dlang.org/post/rzgcenuqiokknpslt...@forum.dlang.org

Reply via email to