I was reading the code for the DCV library and came across this function: https://github.com/libmir/dcv/blob/master/source/dcv/imgproc/color.d#L128

Here is a shortened form:
[return type] rgbbgr2gray(bool isBGR, V)([run-time parameters]){[implementation]}

and an example call:
rgbbgr2gray!(true, [a type])([run-time arguments])

The part that got my attention was `bool isBGR`. I was under the impression that compile-time or template parameters were only for types. Where would one find information on this in the D spec? Why would one write a function this way?

Reply via email to