unicode-data-security-0.2.0: Unicode security mechanisms database
Copyright(c) 2021 Composewell Technologies and Contributors
LicenseApache-2.0
Maintainerstreamly@composewell.com
Stabilityexperimental
Safe HaskellSafe-Inferred
LanguageHaskell2010

Unicode.Char.Identifiers.Security

Description

Unicode Security Mechanisms functions based on Unicode Technical Standard #39.

Since: 0.1.0

Synopsis

Identifier status

isAllowedInIdentifier :: Char -> Bool Source #

Returns True if the given character is allowed in an identifier.

  • Restricted characters should be treated with caution when considering possible use in identifiers, and should be disallowed unless there is good reason to allow them in the environment in question.
  • Allowed characters are not typically used as is by implementations. Instead, they are applied as filters to the set of supported characters.

Since: 0.1.0

Identifier type

data IdentifierType Source #

Identifier type

Since: 0.1.0

Constructors

NotCharacter

Unassigned characters, private use characters, surrogates, non-whitespace control characters.

Deprecated

Characters with the Unicode property Deprecated=Yes.

DefaultIgnorable

Characters with the Unicode property Default_Ignorable_Code_Point=Yes.

NotNFKC

Characters that cannot occur in strings normalized to NFKC.

NotXID

Characters that do not qualify as default Unicode identifiers; that is, they do not have the Unicode property XID_Continue=True.

Exclusion

Characters with Script_Extensions values containing a script in Excluded Scripts, and no script from Limited Use Scripts or Recommended Scripts, other than “Common” or “Inherited”.

Obsolete

Characters that are no longer in modern use, or that are not commonly used in modern text.

Technical

Specialized usage: technical, liturgical, etc.

UncommonUse

Characters that are uncommon, or are limited in use, or whose usage is uncertain.

LimitedUse

Characters from scripts that are in limited use.

Inclusion

Exceptionally allowed characters.

Recommended

Characters from scripts that are in widespread everyday common use.

Instances

Instances details
Bounded IdentifierType Source # 
Instance details

Defined in Unicode.Internal.Char.Security.IdentifierType

Enum IdentifierType Source # 
Instance details

Defined in Unicode.Internal.Char.Security.IdentifierType

Show IdentifierType Source # 
Instance details

Defined in Unicode.Internal.Char.Security.IdentifierType

Eq IdentifierType Source # 
Instance details

Defined in Unicode.Internal.Char.Security.IdentifierType

Ord IdentifierType Source # 
Instance details

Defined in Unicode.Internal.Char.Security.IdentifierType

identifierTypes :: Char -> NonEmpty IdentifierType Source #

Returns the IdentifierTypes corresponding to a character.

Since: 0.1.0

isIdentifierTypeAllowed :: IdentifierType -> Bool Source #

Return True if the given IdentifierType is allowed.

Since: 0.1.0

Confusables

confusablePrototype :: Char -> Maybe String Source #

Returns the prototype of a character if it is unintentionally confusable, else Nothing.

Since: 0.1.0

intentionalConfusables :: Char -> String Source #

Returns the list of intentional confusables of a character, if any.

Since: 0.1.0

isIntentionallyConfusable :: Char -> Bool Source #

Returns True if the character is intentionally confusable.

Since: 0.1.0