survex
survex copied to clipboard
suppress "Separator in survey name" warning
Current survex allows introducing survey name "a.b" implicitly and then entering "a" and "b" one after the other without any warnings:
; no warnings
1 2 1.0 0.0 0.0
2 a.b.1 1.0 90.0 0.0
*begin a
*begin b
1 2 1.0 180.0 0.0
*end b
*end a
However, entering "a.b" directly gives a warning:
; warning: Separator in survey name
1 2 1.0 0.0 0.0
2 a.b.1 1.0 90.0 0.0
*begin a.b
1 2 1.0 180.0 0.0
*end a.b
I see no reason why syntax 2 should be discouraged. This PR suppresses the warning.
I'm not really sold on this change. There is a difference between the two cases - in the first case there's an actual definition of survey a
(albeit one which only contains the definition of a sub-survey), whereas in the second case a
is never actually defined anywhere.
I think the underlying problem here (as it was in #4) is that you want to be able to essentially freely use .
as a character in survey station names, but Survex by default interprets .
as separating levels in the survey hierarchy, and complains based on that interpretation.
And as with #4, I think the better answer if you want to use .
freely is to set a different character as the survey hierarchy level separator and add .
to the characters allowed in a name.
In fact, the option to solve the problem without interfering with the code is probably always the best.