Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Brace matching problems in \href #3613

Open
Toseflo opened this issue Jul 30, 2024 · 1 comment
Open

Brace matching problems in \href #3613

Toseflo opened this issue Jul 30, 2024 · 1 comment
Labels
bug Deficiencies in TeXiFy behaviour. parser Issues for which significant changes in the parser are needed

Comments

@Toseflo
Copy link
Contributor

Toseflo commented Jul 30, 2024

Type of JetBrains IDE (IntelliJ, PyCharm, etc.) and version

IntelliJ IDEA Ultimate 2024.1.4

Operating System

Windows 11

TeXiFy IDEA version

0.9.7

What I did (steps to reproduce)

I wanted to add this bibmacro from stackexchange: https://tex.stackexchange.com/a/48409. IntelliJ gives me multiple warnings, but the code still works.

Minimal example to reproduce the problem

Simply add the following line somewhere.

\href{\thefield{url}}{#1}%

When you look at the brace matching, you notice that the opening bracket of \thefield{ is ignored and the closing bracket after url is treated as the closing bracket of href. This causes the second closing bracket to show an error.

@Toseflo Toseflo added bug Deficiencies in TeXiFy behaviour. untriaged Issue type still needs to be triaged or verified. labels Jul 30, 2024
@PHPirates
Copy link
Collaborator

Many thanks for reporting this, indeed { is not a valid character in a url so this is a brace counting issue in the parser

@PHPirates PHPirates added parser Issues for which significant changes in the parser are needed and removed untriaged Issue type still needs to be triaged or verified. labels Jul 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Deficiencies in TeXiFy behaviour. parser Issues for which significant changes in the parser are needed
Projects
None yet
Development

No branches or pull requests

2 participants