possible REPLACE issue

This forum is meant for questions about the Visual FoxPro Language support in X#.

Post Reply
User avatar
kevclark64
Posts: 127
Joined: Thu Aug 15, 2019 7:30 pm
Location: USA

possible REPLACE issue

Post by kevclark64 »

I don't know if this is a bug or if I'm not doing something correctly, but using the Foxpro dialect the compiler throws an error on this line:

replace field1 with "value", field2 with "value",field3 with "value",field4 with "value"

The error is Parser: unexpected input 'with'

This works fine:

replace field1 with "value", field2 with "value",field3 with "value"
replace field4 with "value"
User avatar
Chris
Posts: 4899
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

possible REPLACE issue

Post by Chris »

Hi Kevin,

This looks like a preprocessor bug, it seems it only allows 3 "subcommands", while it is instructed to allow any number. You can see the commands in C:Program Files (x86)XSharpIncludedbcmd.xh

Problem logged, thanks for the report!
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
FoxProMatt

possible REPLACE issue

Post by FoxProMatt »

Kevin - FYI... They use GitHub Issues to log some bug reports (but not all..).

Anyway, you can track/comment this one here:

https://github.com/X-Sharp/XSharpPublic/issues/300
User avatar
robert
Posts: 4518
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

possible REPLACE issue

Post by robert »

Kevin,
Kevin Clark wrote:I don't know if this is a bug or if I'm not doing something correctly, but using the Foxpro dialect the compiler throws an error on this line:

replace field1 with "value", field2 with "value",field3 with "value",field4 with "value"

The error is Parser: unexpected input 'with'

This works fine:

replace field1 with "value", field2 with "value",field3 with "value"
replace field4 with "value"
Fixed in next build.

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
User avatar
kevclark64
Posts: 127
Joined: Thu Aug 15, 2019 7:30 pm
Location: USA

possible REPLACE issue

Post by kevclark64 »

Great, thanks Robert.

Just to clarify, is there any limit in the number of REPLACEd fields on a single line? The VFP limit is 127.

Kevin
User avatar
robert
Posts: 4518
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

possible REPLACE issue

Post by robert »

Kevin,
Kevin Clark wrote:Great, thanks Robert.

Just to clarify, is there any limit in the number of REPLACEd fields on a single line? The VFP limit is 127.

Kevin
I think the only limit is the amount of memory in your development computer.

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
Post Reply