Skip to content

Line breaks cannot be placed arbitrarily without breaking highlighting #3

@jdghunt

Description

@jdghunt

Line breaks cannot be placed where desired due to highlighting limitations.

For example, consider:

const ram_addr_t[5] SRAM_OFFSETS = {9'd0,
                                    9'd256,
                                    9'd256 + 9'd64,
                                    9'd256 + 9'd64 + 9'd16,
                                    9'd256 + 9'd64 + 9'd16 + 9'd4};

image

vs

const ram_addr_t[5] SRAM_OFFSETS = {9'd0, 9'd256, 9'd256 + 9'd64, 9'd256 + 9'd64 + 9'd16, 9'd256 + 9'd64 + 9'd16 + 9'd4};

image (1)

Both of these are legal, but the former is probably preferable for readability but doesn't highlight.

Similar issues exist with most of the language constructs. Fixing this requires a fundamental change in how the regexes are written given that the Textmate regexes do not support multi-line constructs. In essence, begin/end match systems must be used instead of .* in various places etc.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions