Phix: replace
- Posted by andreasWagner Nov 14, 2024
- 765 views
Hallo,
This code from the Phix Documentation
sequence s
s = replace("John Middle Doe", "Smith", 6, 11)
-- s is "John Smith Doe"
s = replace({45.3, "John", 5, {10, 20}}, 25, 2, 3)
-- s is {45.3, 25, {10, 20}}
Produces this error (testet with Phix 1.04,1.05,1.03)
D:\devpool\projects\demo\easy4hang\rep.exw:2
s = replace("John Middle Doe", "Smith", 6, 11)
^ a namespace qualifier is required
replace is defined in:
D:\devpool\projects\demo\easy4hang\rep.exw:2
s = replace("John Middle Doe", "Smith", 6, 11)
^ a namespace qualifier is required
replace is defined in:
Press Enter, or d for diagnostics...
This are the first lines from ex.er
1..109] = "D:\\devpool\\projects\\demo\\easy4hang\\rep.exw:2\ns = replace(\"John Middle Doe\", \"Smith\", 6, 11)\n ^ a namespace"
errline[110..156] = " qualifier is required\nreplace is defined in:\n\n"
txtline = `s = replace("John Middle Doe", "Smith", 6, 11)`
fni = <novalue>
lt = 47'/'
k = 46'.'
fn = 3
sli = <novalue>
sfi = <novalue>
i = 0
... called from C:\Phixsetup\phix\pmsgs.e:549 in procedure Abort_multi()
msg = "a namespace qualifier is required\nreplace is defined in:\n"
abort_set = {}
f = <novalue>
pathno = <novalue>
ff = <novalue>
dbg = {}
i = 1
... called from C:\Phixsetup\phix\psym.e:3752 in function InTable()
thank you in advance
Andreas

