rl_lang/docs/entries/stdlib/net/
resolve.rs1use crate::docs::entry::FnEntry;
2
3pub static RESOLVE: FnEntry = FnEntry {
4 signature: "resolve(host_port)",
5 description: "resolves \"host:port\" via DNS and returns the resolved IP addresses as strings",
6 example: r#"
7get std::net::resolve
8
9dec array[string] ips = result_unwrap(resolve("example.com:80"))"#,
10 expected_output: None,
11 returns: "Result[array[string]]",
12 errors: Some("Err(string) when the host can't be resolved"),
13 see_also: &["tcp_connect"],
14 since: Some("v0.1.5"),
15};