// Copyright 2021 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package ascii

import (
	
	
)

// EqualFold is [strings.EqualFold], ASCII only. It reports whether s and t
// are equal, ASCII-case-insensitively.
func (,  string) bool {
	if len() != len() {
		return false
	}
	for  := 0;  < len(); ++ {
		if lower([]) != lower([]) {
			return false
		}
	}
	return true
}

// lower returns the ASCII lowercase version of b.
func lower( byte) byte {
	if 'A' <=  &&  <= 'Z' {
		return  + ('a' - 'A')
	}
	return 
}

// IsPrint returns whether s is ASCII and printable according to
// https://tools.ietf.org/html/rfc20#section-4.2.
func ( string) bool {
	for  := 0;  < len(); ++ {
		if [] < ' ' || [] > '~' {
			return false
		}
	}
	return true
}

// Is returns whether s is ASCII.
func ( string) bool {
	for  := 0;  < len(); ++ {
		if [] > unicode.MaxASCII {
			return false
		}
	}
	return true
}

// ToLower returns the lowercase version of s if s is ASCII and printable.
func ( string) ( string,  bool) {
	if !IsPrint() {
		return "", false
	}
	return strings.ToLower(), true
}