aboutsummaryrefslogtreecommitdiffhomepage
path: root/vendor/golang.org/x/text/unicode/norm/composition.go
diff options
context:
space:
mode:
authorNathan Dench <ndenc2@gmail.com>2019-05-24 15:16:44 +1000
committerNathan Dench <ndenc2@gmail.com>2019-05-24 15:16:44 +1000
commit107c1cdb09c575aa2f61d97f48d8587eb6bada4c (patch)
treeca7d008643efc555c388baeaf1d986e0b6b3e28c /vendor/golang.org/x/text/unicode/norm/composition.go
parent844b5a68d8af4791755b8f0ad293cc99f5959183 (diff)
downloadterraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.tar.gz
terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.tar.zst
terraform-provider-statuscake-107c1cdb09c575aa2f61d97f48d8587eb6bada4c.zip
Upgrade to 0.12
Diffstat (limited to 'vendor/golang.org/x/text/unicode/norm/composition.go')
-rw-r--r--vendor/golang.org/x/text/unicode/norm/composition.go8
1 files changed, 6 insertions, 2 deletions
diff --git a/vendor/golang.org/x/text/unicode/norm/composition.go b/vendor/golang.org/x/text/unicode/norm/composition.go
index bab4c5d..e2087bc 100644
--- a/vendor/golang.org/x/text/unicode/norm/composition.go
+++ b/vendor/golang.org/x/text/unicode/norm/composition.go
@@ -407,7 +407,7 @@ func decomposeHangul(buf []byte, r rune) int {
407 407
408// decomposeHangul algorithmically decomposes a Hangul rune into 408// decomposeHangul algorithmically decomposes a Hangul rune into
409// its Jamo components. 409// its Jamo components.
410// See http://unicode.org/reports/tr15/#Hangul for details on decomposing Hangul. 410// See https://unicode.org/reports/tr15/#Hangul for details on decomposing Hangul.
411func (rb *reorderBuffer) decomposeHangul(r rune) { 411func (rb *reorderBuffer) decomposeHangul(r rune) {
412 r -= hangulBase 412 r -= hangulBase
413 x := r % jamoTCount 413 x := r % jamoTCount
@@ -420,7 +420,7 @@ func (rb *reorderBuffer) decomposeHangul(r rune) {
420} 420}
421 421
422// combineHangul algorithmically combines Jamo character components into Hangul. 422// combineHangul algorithmically combines Jamo character components into Hangul.
423// See http://unicode.org/reports/tr15/#Hangul for details on combining Hangul. 423// See https://unicode.org/reports/tr15/#Hangul for details on combining Hangul.
424func (rb *reorderBuffer) combineHangul(s, i, k int) { 424func (rb *reorderBuffer) combineHangul(s, i, k int) {
425 b := rb.rune[:] 425 b := rb.rune[:]
426 bn := rb.nrune 426 bn := rb.nrune
@@ -461,6 +461,10 @@ func (rb *reorderBuffer) combineHangul(s, i, k int) {
461// It should only be used to recompose a single segment, as it will not 461// It should only be used to recompose a single segment, as it will not
462// handle alternations between Hangul and non-Hangul characters correctly. 462// handle alternations between Hangul and non-Hangul characters correctly.
463func (rb *reorderBuffer) compose() { 463func (rb *reorderBuffer) compose() {
464 // Lazily load the map used by the combine func below, but do
465 // it outside of the loop.
466 recompMapOnce.Do(buildRecompMap)
467
464 // UAX #15, section X5 , including Corrigendum #5 468 // UAX #15, section X5 , including Corrigendum #5
465 // "In any character sequence beginning with starter S, a character C is 469 // "In any character sequence beginning with starter S, a character C is
466 // blocked from S if and only if there is some character B between S 470 // blocked from S if and only if there is some character B between S