The problem was in the creation of var options. Changing the line to:
var options
var options = CAresDNSResolver.Options.default
Resolved the problem.