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

Cannot use the word 'String' within double-quotes for Java #13

Closed
dan-j opened this issue Aug 3, 2015 · 2 comments
Closed

Cannot use the word 'String' within double-quotes for Java #13

dan-j opened this issue Aug 3, 2015 · 2 comments
Assignees
Labels
Bug duplicate EnlighterJS v2 legacy EnlighterJS (based on MooTools Framework)
Milestone

Comments

@dan-j
Copy link

dan-j commented Aug 3, 2015

I have the following text in my post:

[java]String str = "A String";[/java]

It renders the following:

String str = "A String"String";

It seems the above example is matching as a string and as a keyword. The HTML looks like the following:

<code data-enlighter-language="java" class="EnlighterJSRAW">String str = &quot;Inline String&quot;;</code>

And the DOM is being rendered:

<span class="beyondEnlighterJS EnlighterJS">
    <span class="kw2">String</span>
    <span class> str = </span>
    <span class="str">"Inline String"</span>
    <span class="kw2">String</span>
    <span class=>";</span>
</span>

I've also verified that the above behaviour occurs if the string is, "A void" (another java keyword).

Hope the above is enough information. It seems like keywords are still being searched even within quotes.

@AndiDittrich
Copy link
Member

Dear dan,
thanks for your report!
the bug is already known and related to the EnlighterJS Tokenizer Engine: EnlighterJS/EnlighterJS#8

A Bugfix release will follow asap!

best regaards, Andi

@AndiDittrich AndiDittrich added Bug duplicate EnlighterJS v2 legacy EnlighterJS (based on MooTools Framework) labels Aug 3, 2015
@AndiDittrich AndiDittrich added this to the 2.9 milestone Aug 3, 2015
@AndiDittrich AndiDittrich self-assigned this Aug 3, 2015
@dan-j
Copy link
Author

dan-j commented Aug 3, 2015

Awesome! I was just looking into how to fix this, cheers for the quick response, it would have been a waste of my time otherwise :)

Cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug duplicate EnlighterJS v2 legacy EnlighterJS (based on MooTools Framework)
Projects
None yet
Development

No branches or pull requests

2 participants