Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Non italics text treated as italics after C code block #214

@g199209

Description

@g199209

Prerequisites

Description

In C language, /* */ stands for comment. But in some case, if we use /* */ in code block, * will be treated as italics begin. This only happen in C or Cpp code block, Java and C# code block do not have this matter.

Steps to Reproduce

  1. Change the file highlight to Github Markdown.
  2. type the following code in a C code block respectively. (See the screenshot below)

{
/* comment */
}

/* comment */

Only the first format will cause some matter. That means /* */ in { }scope.

Expected behavior: [What you expect to happen]

These two code segments are both correct, and the text after the code block should not be italic.

{
    /* comment */
}

This line should not be italic.

    /* comment */

This line should not be italic.

Actual behavior: [What actually happens]

Non italics text treated as italics in first format.

If we delete the first {, the highlight is correct.


And if we change the language of the code block from c to java or c#, this problem do not happen.

Reproduces how often: [What percentage of the time does it reproduce?]

Always.

Versions

Atom : 1.21.0
Electron: 1.6.9
Chrome : 56.0.2924.87
Node : 7.4.0

apm 1.18.5
npm 3.10.10
node 6.9.5 x64
python 3.5.1
git 2.9.3.windows.3
visual studio 2015

OS: Windows 10 64 bit

Additional Information

There are some similar issues:

#198
#133
#171

But this problem still not solved...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions