You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: permissions.rs
    path of file: ./repos/deno/runtime/ops
    
    the code of the file until where you have to start completion: // Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.

use crate::permissions::parse_sys_kind;
use crate::permissions::PermissionState;
use crate::permissions::
    
fn parse_host(host_str: &str) -> Result<(String, Option<u16>), AnyError> {
  let url = url::Url::parse(&format!("http://{host_str}/"))
    .map_err(|_| uri_error("Invalid host"))?;
  if url.path() != "/" {
    return Err(uri_error("Invalid host"));
  }
  let hostname = url.host_str().unwrap();
  Ok((hostname.to_string(), url.port()))
}