<commit_before>var foo = {
  n: 101,
  bar: function() {
    console.assert(this.n === 101, 'invalid value of n, this =', this);
  }
};

foo.bar();
foo.bar.bind(foo)();

var foobar = foo.bar;
try {
  foobar();
  console.log('hmm, no exception thrown!');
  process.exit(-1);
} catch (err) {};

foobar = foo..bar();
foobar();

// do it again for fun
foobar = foo..bar();
foobar();

// function without an object
function add(a, b) { return a + b; }
console.assert(add(2, 3) === 5, '2+3 = 5');
console.assert(add..(2)(3) === 5, '..2+3 = 5');
console.assert(add..(10, 11)() === 21, '..10,11 = 21');
<commit_msg>testing if the function is executed right away<commit_after>var foo = {
  n: 101,
  bar: function() {
    console.log('foo.bar');
    console.assert(this.n === 101, 'invalid value of n, this =', this);
  }
};

foo.bar();
console.log('binding using function.bind');
foo.bar.bind(foo)();
console.log('bound');

var foobar = foo.bar;
try {
  foobar();
  console.log('hmm, no exception thrown!');
  process.exit(-1);
} catch (err) {};

console.log('binding using .. syntax');
foobar = foo..bar();
console.log('trying the dotdot function');
foobar();

// do it again for fun
foobar = foo..bar();
foobar();

// function without an object
function add(a, b) { return a + b; }
console.assert(add(2, 3) === 5, '2+3 = 5');
console.assert(add..(2)(3) === 5, '..2+3 = 5');
console.assert(add..(10, 11)() === 21, '..10,11 = 21');

{'fraction_non_alphanumeric': 0.2345505617977528, 'fraction_numerical': 0.04353932584269663, 'mean_word_length': 3.656862745098039, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5722313', 'n_tokens_mistral': 590, 'n_tokens_neox': 535, 'n_words': 145}