Kwarg depending on type of another kwarg

I want to define a keyword argument that depends on the type of another keyword argument. For example,

function testf(c; a::A = 0.0, b::NTuple{2, Type{A}} = (A, A)) where A end 

This is not possible, though:

julia> testf(0.0)
ERROR: UndefVarError: A not defined

Is there anyway to get around this? Even defining all the keyword arguments fails:

testf(0.0; a=0.0, b=(Float64, Float64))
julia> testf(0.0;a=0.0,b=(Float64,Float64))
ERROR: MethodError: no method matching var"#testf#97"(::Float64, ::Tuple{DataType, DataType}, ::typeof(testf), ::Float64)
Closest candidates are:
  var"#testf#97"(::A, ::Tuple{Type{A}, Type{A}}, ::typeof(testf), ::Any) where A

A is a DataType, so the signature b::NTuple{2, Type{A}} = (A, A) doesn’t really make sense. Actually, it kinda does, but still doesn’t work because the Type{A} is not a concrete type.

If you do

julia> function foo(c; a::A = 0.0, b::NTuple{2, DataType} = (typeof(a), typeof(a))) where A
foo (generic function with 1 method)

julia> foo(0.0)
(Float64, Float64)

You get what you want (I think).