Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-35100

Warnings Compiler Plugin for Visual Studio c++

    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Minor Minor
    • warnings-plugin
    • None
    • warnings-plugin

      Visual Studio c++ compiler warnings are not detected by warnings plugin.

      I used Clang, Sun c+, TI code composer studio (c/c+), Wind river, Cpplinit. But nothing works out.

      E.g warning:
      "C:\Jenkins\val.vcxproj" (Rebuild target) (19) ->
      src\path\to\hello.cpp(310): warning C4244: '=' : conversion from 'double' to 'int', possible loss of data

      Am I missing something?

          [JENKINS-35100] Warnings Compiler Plugin for Visual Studio c++

          Tamil Selvan created issue -
          Tamil Selvan made changes -
          Description Original: Visual Studio c++ compiler warnings are not detected by warnings plugin.

          I used Clang, Sun c++, TI code composer studio (c/c++), Wind river, CppInit. But nothing works out.

          E.g warning:
          "C:\Jenkins\val.vcxproj" (Rebuild target) (19) ->
            src\path\to\hello.cpp(310): warning C4244: '=' : conversion from 'double' to 'int', possible loss of data

          Am I missing something?
          New: Visual Studio c++ compiler warnings are not detected by warnings plugin.

          I used Clang, Sun c++, TI code composer studio (c/c++), Wind river, Cpplinit. But nothing works out.

          E.g warning:
          "C:\Jenkins\val.vcxproj" (Rebuild target) (19) ->
            src\path\to\hello.cpp(310): warning C4244: '=' : conversion from 'double' to 'int', possible loss of data

          Am I missing something?

          Ulli Hafner added a comment -

          Did you try MS Build parser?

          Ulli Hafner added a comment - Did you try MS Build parser?
          Ulli Hafner made changes -
          Issue Type Original: Bug [ 1 ] New: New Feature [ 2 ]

          Tamil Selvan added a comment -

          MSBuild works out.
          Thanks a lot for the quick response.

          Nevertheless I made a parser to skip build target warning:

          Regex

          ^\s*(.*)\((\d+)\):\s*warning\s(.*?):\s(.*)(\[.*\])
          

          Groovy Script

          import hudson.plugins.warnings.parser.Warning
          
          String fileName = matcher.group(1)
          String lineNumber = matcher.group(2)
          String category = matcher.group(3)
          String message = matcher.group(4)
          
          return new Warning(fileName, Integer.parseInt(lineNumber), "VSc++", category, message);
          

          Tamil Selvan added a comment - MSBuild works out. Thanks a lot for the quick response. Nevertheless I made a parser to skip build target warning: Regex ^\s*(.*)\((\d+)\):\s*warning\s(.*?):\s(.*)(\[.*\]) Groovy Script import hudson.plugins.warnings.parser.Warning String fileName = matcher.group(1) String lineNumber = matcher.group(2) String category = matcher.group(3) String message = matcher.group(4) return new Warning(fileName, Integer .parseInt(lineNumber), "VSc++" , category, message);

          Tamil Selvan added a comment -

          MSBuild works out.

          Tamil Selvan added a comment - MSBuild works out.
          Tamil Selvan made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Closed [ 6 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 171319 ] New: JNJira + In-Review [ 210076 ]

            drulli Ulli Hafner
            tamsha Tamil Selvan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: