<commit_before>// Copyright (c) 2013 GitHub, Inc.
// Use of this source code is governed by the MIT license that can be
// found in the LICENSE file.

#include "atom/common/api/object_life_monitor.h"
#include "atom/common/node_includes.h"
#include "native_mate/dictionary.h"
#include "v8/include/v8-profiler.h"

namespace {

v8::Local<v8::Object> CreateObjectWithName(v8::Isolate* isolate,
                                            v8::Local<v8::String> name) {
  v8::Local<v8::FunctionTemplate> t = v8::FunctionTemplate::New(isolate);
  t->SetClassName(name);
  return t->GetFunction()->NewInstance();
}

v8::Local<v8::Value> GetHiddenValue(v8::Local<v8::Object> object,
                                     v8::Local<v8::String> key) {
  return object->GetHiddenValue(key);
}

void SetHiddenValue(v8::Local<v8::Object> object,
                    v8::Local<v8::String> key,
                    v8::Local<v8::Value> value) {
  object->SetHiddenValue(key, value);
}

void DeleteHiddenValue(v8::Local<v8::Object> object,
                       v8::Local<v8::String> key) {
  object->DeleteHiddenValue(key);
}

int32_t GetObjectHash(v8::Local<v8::Object> object) {
  return object->GetIdentityHash();
}

void SetDestructor(v8::Isolate* isolate,
                   v8::Local<v8::Object> object,
                   v8::Local<v8::Function> callback) {<commit_msg>Optimize the case when creating plain object<commit_after>// Copyright (c) 2013 GitHub, Inc.
// Use of this source code is governed by the MIT license that can be
// found in the LICENSE file.

#include "atom/common/api/object_life_monitor.h"
#include "atom/common/node_includes.h"
#include "native_mate/dictionary.h"
#include "v8/include/v8-profiler.h"

namespace {

v8::Local<v8::Object> CreateObjectWithName(v8::Isolate* isolate,
                                           const std::string& name) {
  if (name == "Object")
    return v8::Object::New(isolate);
  v8::Local<v8::FunctionTemplate> t = v8::FunctionTemplate::New(isolate);
  t->SetClassName(mate::StringToV8(isolate, name));
  return t->GetFunction()->NewInstance();
}

v8::Local<v8::Value> GetHiddenValue(v8::Local<v8::Object> object,
                                    v8::Local<v8::String> key) {
  return object->GetHiddenValue(key);
}

void SetHiddenValue(v8::Local<v8::Object> object,
                    v8::Local<v8::String> key,
                    v8::Local<v8::Value> value) {
  object->SetHiddenValue(key, value);
}

void DeleteHiddenValue(v8::Local<v8::Object> object,
                       v8::Local<v8::String> key) {
  object->DeleteHiddenValue(key);
}

int32_t GetObjectHash(v8::Local<v8::Object> object) {
  return object->GetIdentityHash();
}

void SetDestructor(v8::Isolate* isolate,
                   v8::Local<v8::Object> object,
                   v8::Local<v8::Function> callback) {
{'fraction_non_alphanumeric': 0.14855328158080452, 'fraction_numerical': 0.027522935779816515, 'mean_word_length': 3.2376681614349776, 'pattern_counts': {'":': 0, '<': 30, '<?xml version=': 0, '>': 44, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1990532', 'n_tokens_mistral': 944, 'n_tokens_neox': 914, 'n_words': 171}