How does grafana $__timegroup[fillvalue] works?

Hi there,
I have a quick question that how does grafana ‘fill value option in $__timegroup’ works.

When the real data is like
time. value
00:00:00 100
00:00:10 100
00:00:30 100

__timeGroup(time, __interval,0) finds the hole in the data and fill it as 0.
When __timeGroup(time, __interval,‘previous’), grafana fills the hole as 100.

However, the generated query is same whether I use ‘__timeGroup(time, __interval,0)’ or ‘__timeGroup(time, __interval,‘previous’)’.

So, I come to wonder how does this [fillvalue] option in $__timeGroup works. Is it a special logic in grafana source rather than controlling a query?