Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • D dynamorio
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,467
    • Issues 1,467
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 44
    • Merge requests 44
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • DynamoRIO
  • dynamorio
  • Merge requests
  • !2775

Resolve 'variable' hides previous declaration in dynamorio project

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Administrator requested to merge github/fork/vbaderks/iX-cpp-compile-improvements-2 into master Dec 16, 2017
  • Overview 20
  • Commits 7
  • Pipelines 0
  • Changes 8

Created by: vbaderks

MSVC++ 14.12 will report the following compiler warning:

  • C4456 declaration of 'variable' hides previous local declaration This is a default Level4 warning in MSVC++ 14.12 which causes the project to fail as /WX is defined. This warning is generated since Visual Studio 2015.

This warning has been resolved by: A) reusing the original definition. B) using a different name for the second declaration. Depending on the size of the function implementation and location of the second declaration, option A or B has been used to keep the code as clear as possible.

Note: also resolves incorrect usage of the NULL macro, defined as ((void *)0), when a bool or uint64 type is required.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: github/fork/vbaderks/iX-cpp-compile-improvements-2