Export `RE.Regex`, and make constructors easier.
panxiaoguang opened this issue · 2 comments
panxiaoguang commented
I want to have a regex search search for biosequences, and it can be changed by a value.
for example,
start="AGCAT"
re=@biore_str(string(start,"[AGCT]+"),"d")
it always repored an error, but I want it can be changed by start value?
jakobnissen commented
You can do this by explicitly constructing the regex:
julia> start="AGCAT"
"AGCAT"
julia> BioSequences.RE.Regex{DNA}(start * "[ACGT]+", :pcre)
biore"AGCAT[ACGT]+"dna
This functionality ought to be exposed - in general it's good style that, whenever you have a macro exported, also export the equivalent function.
jakobnissen commented
Resolved in #169