Sign in Join
FPDoc Onlineexperiment

UTF8BOMToUTF8 function

In unit LConvEncoding

Removes the UTF-8 BOM from the UTF-8 encoded value.

Declaration

pascal
function UTF8BOMToUTF8(const s: string): string

Arguments

s

UTF-8-encoded value examined in the routine.

Function result

Value after removing the UTF-8 BOM.

Description

The return value is the value in s after removing the Byte Order Mark in UTF8BOM from the start of the string. The return value is the same as the value in s when UTF8BOM is not found in the string.

No actions are performed in the routine when s is an empty string (''). The return value is also an empty string.

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.