Unicode文字列

Unicode文字列

[12] 文字列 (もじれつ) (string) は、符号位置 (sequence) です >>11

仕様書

用語

[14] Encoding Standard符号位置の列としていますが、 その他の文脈ではUnicodeスカラー値の列が文字列と呼ばれることもあります。 多くの場合、どちらであるかは曖昧です。

[13] 現代では普通は文字列というと、 Unicode文字列 (Unicode string) のことを指しています。 他の文字コード文字列が使われることはほとんどなくなってきています。


[29] 符号化済文字列 (ふごうかずみもじれつ) (coded character sequence) (符号化済文字表現 (ふごうかずみもじひょうげん) (coded character representation) ) は、 1つ以上符号点順序付き列です。 >>35 D12 The Unicode Standard では、特に断らない限り、 文字 (もじ) (れつ) (character sequence) とは符号化済文字列です >>35

[30] 名前に反して符号化済文字の列ではありません。 通常は符号化済文字で構成されますが、 それ以外に非文字予約済符号点を含むこともあります。

[31] 符号化済文字列
  1. +
    1. 符号点

[34] Unicode文字列 (もじれつ) (string) は、 特定の Unicode符号化形符号単位を含んだ符号単位列です。 >>33 D80

[36] Unicode文字列
  1. +
    1. 符号単位

[32] 符号化済文字列Unicode文字列抽象文字列は似たように見えて構成要素が違います。

[37] これら Unicode 系の定義は空文字列を認めていません。

演算

[39] 文字列演算

関連

[15] 歴史的にはよくバイト列オクテット列と混同されていました。 現代のプログラミング言語などでは明確に区別するのが普通ですが、 暗黙のうちに型変換される場合もあり、取り扱いには注意が必要です。 プロトコル仕様書などでは現在でも区別が不明瞭なことがあり、 注意が必要です。

メモ

[1]

(298) (文字)列 [(character) string]
文字並びJIS X 4151-1992 3.

[2] JavaScript の文字列連結ベンチマーク - ぐま あーかいぶ ( ( 版)) http://archive.guma.jp/2010/11/javascript-1.html

[3] JavaScript - 文字列の結合方法による速度差 - Qiita ( ( 版)) http://qiita.com/se_ino/items/0322e0820badf2c020be

[4] 文字列の結合 - ひきメモ ( ( 版)) http://d.hatena.ne.jp/yumimue/20071226/1198670253

[5] 文字列操作の速度比較 - misc.log ( ( 版)) http://backyard.hatenablog.com/entry/20041202/1173749287

[6] 理由がない限り、Array.join("") による文字列連結は使わないほうがいいみたい - latest log ( ( 版)) http://d.hatena.ne.jp/uupaa/20090828/1251418928

[7] ( ( 版)) http://ll.jus.or.jp/2011/slide/LT/2011-LL-kuwata.pdf

[8] XQuery and XPath Data Model 3.0 ( ( 版)) http://www.w3.org/TR/xpath-datamodel-3/#dt-string

[9] XPath and XQuery Functions and Operators 3.0 ( ( 版)) http://www.w3.org/TR/xpath-functions-3/#string

[10] Character Model for the World Wide Web 1.0: Fundamentals ( ( 版)) http://www.w3.org/TR/charmod/#def-character-string

[16] Editorial: start using the Infra Standard (annevk著, ) https://github.com/whatwg/encoding/commit/a26f76889bf393999e9caad84a3647ab09c39e09

[17] XQuery and XPath Data Model 3.1 () https://www.w3.org/TR/2017/REC-xpath-datamodel-31-20170321/#dt-string

[18] XPath and XQuery Functions and Operators 3.1 () https://www.w3.org/TR/2017/REC-xpath-functions-31-20170321/#string

[19] Define JavaScript string and scalar value string (annevk著, ) https://github.com/whatwg/infra/commit/f1be763cfba23d2fc780b35403074c599e69616e

[20] String byte escapes seem wrong · Issue #577 · WebAssembly/spec () https://github.com/WebAssembly/spec/issues/577

[21] Strings on the Web: Language and Direction Metadata () https://w3c.github.io/string-meta/

[22] Strings on the Web: Language and Direction Metadata () https://www.w3.org/TR/2019/WD-string-meta-20190611/

[23] Strings on the Web: Language and Direction Metadata () https://www.w3.org/TR/2019/WD-string-meta-20190416/

[24] Editorial: rename "Plain Unicode string" to "text" for drag data store (karx著, ) https://github.com/whatwg/html/commit/817ee1b69398ea385d639a35450cc218463bff0d

[25] Plain Unicode string · Issue #4798 · whatwg/html · GitHub () https://github.com/whatwg/html/issues/4798

[26] [Re] Rename "Plain Unicode string" to "text" by karx · Pull Request #4827 · whatwg/html · GitHub () https://github.com/whatwg/html/pull/4827

[27] Incorrect algorithm for byte sequence starts with and string code unit prefix · Issue #256 · whatwg/infra () https://github.com/whatwg/infra/issues/256

[28] Fix "starts with" and "code unit prefix" algorithm by al-arz · Pull Request #259 · whatwg/infra () https://github.com/whatwg/infra/pull/259

[38] UTS #18: Unicode Regular Expressions, , https://unicode.org/reports/tr18/#character_ranges

For the purpose of regular expressions, in this document the terms “character” and “code point” are used interchangeably. Similarly, the terms “string” and “sequence of code points” are used interchangeably.