net: replaced RegExpPrototypeTest with RegExpPrototypeExec for ip check
Took care of the todo in lib/internal/net.js
which suggested to replace RegExpPrototypeTest
with RegExpPrototypeExec
when checking for the IP version.
I am not sure if it no longer creates a perf regression in the dns benchmark; I ran the benchmark locally and everything looks fine, I guess I need a CI to verify it.