Hi Maarten,
Thank you for your kind reply. I have already tested the expression you
suggest (I haven't tried that variant yet) and the result is the same. The
fact is that it is a bit strange that it works for one subexpression and
not for another very similar one.
Regards.
El domingo, 14 de enero de 2024 a las 20:09:34 UTC+1, Maarten Sneep
escribió:
> Hi,
>
> I think you need to anchor the whole expression:
>
> (?x:
> ^(([a-zA-Z_]{1}[a-zA-Z0-9_]*:)|
> ([1-9]{1}[0-9]*))
> )
>
> (I have not tested this yet).
>
> Maarten
>
> On 14 Jan 2024, at 11:32, Joaquin Adiego <[email protected]> wrote:
>
> Hi,
>
> I'm developing a codeless language module for Boriel ZX Basic. Everything
> works fine except the labels (which can be the old Basic line numbers, at
> the beginning of the line, or an identifier ending with ':' also at the
> beginning of a line). I have used regular expressions to recognize all
> language elements (see file attached). Numeric tags are recognized well
> (appearing in green, see the screenshot attached), but text tags are not,
> recognizing strings that are not at the beginning of a line as tags as
> well. The two regular expressions are similar, so I don't understand very
> well why it works well in one case and doesn't work in the other. I have
> tried rewriting the regular expression in different ways but have not been
> successful, so I deduce that the problem must lie in the module
> specification, but I am not able to locate it.
>
> Can anyone help me with this?
>
> Regards
>
>
>
> --
> This is the BBEdit Talk public discussion group. If you have a feature
> request or need technical support, please email "[email protected]"
> rather than posting here. Follow @bbedit on Twitter: <
> https://twitter.com/bbedit>
> ---
> You received this message because you are subscribed to the Google Groups
> "BBEdit Talk" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/bbedit/cf17d86a-e9dc-4851-bfb3-e82ae386008an%40googlegroups.com
>
> <https://groups.google.com/d/msgid/bbedit/cf17d86a-e9dc-4851-bfb3-e82ae386008an%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> <Captura de pantalla 2024-01-14 a las 11.17.03.png><BorielBasic.plist>
>
>
>
--
This is the BBEdit Talk public discussion group. If you have a feature request
or need technical support, please email "[email protected]" rather than
posting here. Follow @bbedit on Twitter: <https://twitter.com/bbedit>
---
You received this message because you are subscribed to the Google Groups
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/bbedit/fbdca795-6674-41ea-9915-2c29c898a808n%40googlegroups.com.