Github user srowen commented on a diff in the pull request:

    https://github.com/apache/spark/pull/4972#discussion_r26387439
  
    --- Diff: core/src/main/scala/org/apache/spark/util/SizeEstimator.scala ---
    @@ -184,14 +182,14 @@ private[spark] object SizeEstimator extends Logging {
       private val ARRAY_SIZE_FOR_SAMPLING = 200
       private val ARRAY_SAMPLE_SIZE = 100 // should be lower than 
ARRAY_SIZE_FOR_SAMPLING
     
    -  private def visitArray(array: AnyRef, cls: Class[_], state: SearchState) 
{
    -    val length = JArray.getLength(array)
    -    val elementClass = cls.getComponentType
    +  private def visitArray(array: AnyRef, arrayClass: Class[_], state: 
SearchState) {
    +    val length = ScalaRunTime.array_length(array)
    +    val elementClass = arrayClass.getComponentType()
    --- End diff --
    
    I think it's OK to add () since they're java methods and are technically 
declared with (). I think they have no side effects though. More of an 
observation than anything.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to