Skip to content

Capture comments by providing the parent node #231

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

Merged
merged 1 commit into from
Jan 15, 2022

Conversation

planetis-m
Copy link
Contributor

@planetis-m planetis-m commented Jan 14, 2022

Currently c2nim skips comments after a constant expression, at the end of an enum (without a comma):

// Shader attribute data types
typedef enum {
    SHADER_ATTRIB_FLOAT = 0,           // Shader attribute type: float
    SHADER_ATTRIB_VEC2 = 1,            // Shader attribute type: vec2 (2 float)
    SHADER_ATTRIB_VEC3 = 2,            // Shader attribute type: vec3 (3 float)
    SHADER_ATTRIB_VEC4 =  3            // Shader attribute type: vec4 (4 float) <- warning: skipped comment ...
} ShaderAttributeDataType;

not sure if that's an acceptable solution but it can be extended for #define as well

@Araq Araq merged commit 87c2acb into nim-lang:master Jan 15, 2022
@Araq
Copy link
Member

Araq commented Jan 15, 2022

It's good.

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.

2 participants