awl/pkg/resolvers/QUIC_gccgo.go
Sam Therapy bb8b00a888
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is passing
feat(gccgo): allow compilation with gccgo
GCCGo doesn't support generics so QUIC needs to be disabled

Signed-off-by: Sam Therapy <sam@samtherapy.net>
2022-11-19 19:12:31 +01:00

26 lines
656 B
Go

// SPDX-License-Identifier: BSD-3-Clause
//go:build gccgo
// TODO: Whenever gccgo supports quic-go, delete this
package resolvers
import (
"errors"
"git.froth.zone/sam/awl/pkg/util"
"github.com/miekg/dns"
)
// QUICResolver is for DNS-over-QUIC queries.
type QUICResolver struct {
opts *util.Options
}
var _ Resolver = (*QUICResolver)(nil)
var errNotImplemented = errors.New("DNS-over-QUIC not supported when running gccgo!")
// LookUp cannot be used with gccgo because gccgo does not (and likely will not) support generics.
func (resolver *QUICResolver) LookUp(msg *dns.Msg) (util.Response, error) {
return util.Response{}, errNotImplemented
}