Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-7542

CompileStatic class generation bug "register with message: rightShiftUnsigned and arguments X"

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.4.4
    • 2.4.8
    • Static compilation
    • None
    • Groovy Version: 2.4.4 JVM: 1.7.0_55 Vendor: Oracle Corporation OS: Linux

    Description

      Error caused by the following code snippet (was in the process of coding a crc64 algorithm):

      import groovy.transform.CompileStatic 
      
      test()
      
      @CompileStatic
      def test() {
        long register = 0xfac432b10cd5e44aL  
        
        [1,2,3].each { int element -> 
          int t = (int) (register >>> 56 ^ (long) element) & 0xff
        }  
      }
      

      execution example:

      $ groovy test.groovy 
      
      Caught: BUG! exception in phase 'class generation' in source unit '/home/mbjarland/test.groovy' At line 11 column 20
      
      On receiver: register with message: rightShiftUnsigned and arguments: 56
      This method should not have been called. Please try to create a simple example reproducing this error and filea bug report at https://issues.apache.org/jira/browse/GROOVY
      
      BUG! exception in phase 'class generation' in source unit '/home/mbjarland/projects/kohler.project/projects/full-publish/test.groovy' At line 11 column 20
      
      On receiver: register with message: rightShiftUnsigned and arguments: 56
      This method should not have been called. Please try to create a simple example reproducing this error and filea bug report at https://issues.apache.org/jira/browse/GROOVY
      

      Attachments

        Issue Links

          Activity

            People

              paulk Paul King
              mbjarland Matias Bjarland
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: