<commit_before>import { metaFor, trackedGet } from '@glimmer/tracking';
import { CURRENT_TAG } from '@glimmer/reference';

import GlimmerComponent from '../addon/-private/component';
import { assert } from '@glimmer/util';

export interface Bounds {
  firstNode: Node;
  lastNode: Node;
}

export default class Component extends GlimmerComponent<any> {
  get args() {
    trackedGet(this, 'args');
    return this.__args__;
  }

  set args(args) {
    this.__args__ = args;
    metaFor(this)
      .updatableTagFor('args')
      .inner.update(CURRENT_TAG);
  }

  /** @private
   * Slot on the component to save Arguments object passed to the `args` setter.
   */
  private __args__: any;

  /**
   * Development-mode only name of the component, useful for debugging.
   */
  debugName: string | null = null;

  toString() {
    return `${this.debugName} component`;
  }

  /*
   * Legacy DOM access and lifecycle hooks. These will be deprecated in favor
   * of render modifiers once Glimmer.js supports an element modifier manager
   * API.
   */

  /**
   * Called when the component has been inserted into the DOM.
   * Override this function to do any set up that requires an element in the document body.
   */
  didInsertElement() {}

  /**
   * Called when the component has updated and rerendered itself.<commit_msg>component is generic over args<commit_after>import { metaFor, trackedGet } from '@glimmer/tracking';
import { CURRENT_TAG } from '@glimmer/reference';

import GlimmerComponent from '../addon/-private/component';
import { assert } from '@glimmer/util';

export interface Bounds {
  firstNode: Node;
  lastNode: Node;
}

export default class Component<T extends object = object> extends GlimmerComponent<T> {
  get args() {
    trackedGet(this, 'args');
    return this.__args__;
  }

  set args(args) {
    this.__args__ = args;
    metaFor(this)
      .updatableTagFor('args')
      .inner.update(CURRENT_TAG);
  }

  /** @private
   * Slot on the component to save Arguments object passed to the `args` setter.
   */
  private __args__: T;

  /**
   * Development-mode only name of the component, useful for debugging.
   */
  debugName: string | null = null;

  toString() {
    return `${this.debugName} component`;
  }

  /*
   * Legacy DOM access and lifecycle hooks. These will be deprecated in favor
   * of render modifiers once Glimmer.js supports an element modifier manager
   * API.
   */

  /**
   * Called when the component has been inserted into the DOM.
   * Override this function to do any set up that requires an element in the document body.
   */
  didInsertElement() {}

  /**
   * Called when the component has updated and rerendered itself.
{'fraction_non_alphanumeric': 0.10371747211895911, 'fraction_numerical': 0.0, 'mean_word_length': 3.2244897959183674, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6020979', 'n_tokens_mistral': 817, 'n_tokens_neox': 786, 'n_words': 278}