You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@daffodil.apache.org by GitBox <gi...@apache.org> on 2018/09/13 14:21:20 UTC

[GitHub] mbeckerle commented on a change in pull request #120: Support more versions of Java

mbeckerle commented on a change in pull request #120: Support more versions of Java
URL: https://github.com/apache/incubator-daffodil/pull/120#discussion_r217402720
 
 

 ##########
 File path: daffodil-io/src/main/scala/org/apache/daffodil/io/DataOutputStreamImplMixin.scala
 ##########
 @@ -534,16 +534,16 @@ trait DataOutputStreamImplMixin extends DataStreamCommonState
 
     Assert.usage(bb.remaining() == numBytesForLengthInBits)
 
-    if (nFragBits > 0) bb.limit(bb.limit - 1) // last byte is the frag byte
+    if (nFragBits > 0) bb.limit(bb.limit() - 1) // last byte is the frag byte
     val nBytesWritten = putByteBuffer(bb, finfo) // output all but the frag byte if there is one.
     val nBitsWritten = nBytesWritten * 8
     if (nBytesWritten < nWholeBytes) {
       nBytesWritten * 8
     } else {
       val isFragWritten =
         if (nFragBits > 0) {
-          bb.limit(bb.limit + 1)
-          var fragByte: Long = Bits.asUnsignedByte(bb.get(bb.limit - 1))
+          bb.limit(bb.limit() + 1)
+          var fragByte: Long = Bits.asUnsignedByte(bb.get(bb.limit() - 1))
 
 Review comment:
   So, to avoid re-injecting things like this, I need to change IDE settings or environment vars or something to somehow tell scala that it is expecting a Java 10 underneath not Java 1.8?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services