Skip to content

Unused macro, misleading comments regarding sscanf #130

@dan-so

Description

@dan-so

Commit 96150ba removed all calls to sscanf, but it's still referenced in a comment here:
https://github.com/kgabis/parson/blob/master/parson.c#L594

I don't know how much (if any) of this comment is still accurate.

This same commit added the line
#define sscanf THINK_TWICE_ABOUT_USING_SSCANF

This is a logical way to prevent use of this function, but recent compilers will warn about unused macros (and often this warning is enabled by -Wall or -Wextra).

I propose either of these fixes to remove this warning:

  • explicitly pass -Wno-unused-macros to gcc
  • remove the macro from the source file and pass -D sscanf=THINK_TWICE_ABOUT_USING_SSCANF to gcc

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions