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

lexers: devicetree: allow node label without root node #1755

Merged

Conversation

gmarull
Copy link
Contributor

@gmarull gmarull commented Mar 23, 2021

It is sometimes useful to render DeviceTree snippets such as:

foo: bar@1234 {
    foo = "bar";
};

However, the snippet shown above does not render properly unless it is
enclosed on a root node, i.e.

/{
    foo: bar@1234 {
        foo = "bar";
    };
};

Fixes #1754

@gmarull
Copy link
Contributor Author

gmarull commented Mar 25, 2021

cc: @MaximeChretien

@birkenfeld
Copy link
Member

Thanks for the PR! Can you add a test snippet to exercise the new behavior?

@gmarull
Copy link
Contributor Author

gmarull commented Mar 29, 2021

@birkenfeld done

It is sometimes useful to render DeviceTree snippets such as:

foo: bar@1234 {
    foo = "bar";
};

However the snipper shown above does not render properly unless it is
enclosed on a root node, i.e.

/{
    foo: bar@1234 {
        foo = "bar";
    };
};

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
@gmarull gmarull force-pushed the feature/allow-devicetree-root-nodelabels branch from 20e0754 to 7dafed8 Compare March 29, 2021 21:20
@Anteru Anteru merged commit 1417210 into pygments:master Apr 5, 2021
@Anteru Anteru added this to the 2.9 milestone Apr 5, 2021
@Anteru Anteru added the changelog-update Items which need to get mentioned in the changelog label Apr 5, 2021
@gmarull gmarull deleted the feature/allow-devicetree-root-nodelabels branch April 5, 2021 17:45
@Anteru Anteru removed the changelog-update Items which need to get mentioned in the changelog label Dec 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Devicetree lexer does not node label without root node
4 participants