Skip to content

Commit 9947193

Browse files
committed
Converge TaggedString terminology: use annotations
Instead of having a split between Tags/Annotations/Text properties (regions of the string are annotated with tagged values, and this is a property of the text), just have Tags/Annotations. In line with this, the "properties" field of TaggedString/TaggedChar is renamed to "annotations", and the getter/setter functions are renamed: - textproperties -> annotations - textproperty! -> annotate! While we're at it, improve the docstrings and functions a bit.
1 parent 0001380 commit 9947193

File tree

10 files changed

+138
-104
lines changed

10 files changed

+138
-104
lines changed

base/exports.jl

+2-2
Original file line numberDiff line numberDiff line change
@@ -1094,9 +1094,9 @@ public
10941094
UUID,
10951095

10961096
# Tagged strings
1097-
textproperties,
1098-
textproperty!,
10991097
taggedstring,
1098+
annotate!,
1099+
annotations,
11001100

11011101
# Semaphores
11021102
Semaphore,

base/regex.jl

+1-1
Original file line numberDiff line numberDiff line change
@@ -709,7 +709,7 @@ struct RegexMatchIterator{S <: AbstractString}
709709
RegexMatchIterator(regex::Regex, string::AbstractString, ovr::Bool=false) =
710710
new{String}(regex, String(string), ovr)
711711
RegexMatchIterator(regex::Regex, string::TaggedString, ovr::Bool=false) =
712-
new{TaggedString{String}}(regex, TaggedString(String(string.string), string.properties), ovr)
712+
new{TaggedString{String}}(regex, TaggedString(String(string.string), string.annotations), ovr)
713713
end
714714
compile(itr::RegexMatchIterator) = (compile(itr.regex); itr)
715715
eltype(::Type{<:RegexMatchIterator}) = RegexMatch

0 commit comments

Comments
 (0)