<commit_before>/* NSC -- new Scala compiler
 * Copyright 2005-2010 LAMP/EPFL
 * @author <NAME>
 */

//
// TODO, if practical:
//
// 1) Types: val s: String = x.<tab> should only show members which result in a String.
//      Possible approach: evaluate buffer as if current identifier is
// 2) Implicits: x.<tab> should show not only x's members but those of anything for which
//      there is an implicit conversion from x.
// 4) Imports: after import scala.collection.mutable._, HashMap should be among
//      my top level identifiers.
// 5) Caching: parsing the jars every startup seems wasteful, but experimentally
//      there is little to no gain from caching.

package scala.tools.nsc
package interpreter

import jline._
import java.net.URL
import java.util.{ List => JList }
import java.lang.reflect
import scala.tools.util.PathResolver
import io.{ Path, Directory }

object Completion {
  // methods to leave out of completion
  val excludeMethods = List("hashCode", "equals", "wait", "notify", "notifyAll")

  // strings to look for an exclude by default
  val excludeStrings = List("$$super", "MODULE$")

  def looksLikeInvocation(code: String) = (
        (code != null)
    &&  (code startsWith ".")
    && !(code startsWith "./")
    && !(code startsWith "..")<commit_msg>Stack overflow corner case I noticed in the repl.<commit_after>/* NSC -- new Scala compiler
 * Copyright 2005-2010 LAMP/EPFL
 * @author <NAME>
 */

//
// TODO, if practical:
//
// 1) Types: val s: String = x.<tab> should only show members which result in a String.
//      Possible approach: evaluate buffer as if current identifier is
// 2) Implicits: x.<tab> should show not only x's members but those of anything for which
//      there is an implicit conversion from x.
// 4) Imports: after import scala.collection.mutable._, HashMap should be among
//      my top level identifiers.
// 5) Caching: parsing the jars every startup seems wasteful, but experimentally
//      there is little to no gain from caching.

package scala.tools.nsc
package interpreter

import jline._
import java.net.URL
import java.util.{ List => JList }
import java.lang.reflect
import scala.tools.util.PathResolver
import io.{ Path, Directory }

object Completion {
  // methods to leave out of completion
  val excludeMethods = List("hashCode", "equals", "wait", "notify", "notifyAll")

  // strings to look for an exclude by default
  val excludeStrings = List("$$super", "MODULE$")

  def looksLikeInvocation(code: String) = (
        (code != null)
    &&  (code startsWith ".")
    && !(code == ".")
    && !(code startsWith "./")
    && !(code startsWith "..")
{'fraction_non_alphanumeric': 0.12101669195751139, 'fraction_numerical': 0.009104704097116844, 'mean_word_length': 3.260096930533118, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6886275', 'n_tokens_mistral': 783, 'n_tokens_neox': 745, 'n_words': 307}