<commit_before>const React = require('react');
const classNames = require('classnames');

const {
  tapeContainer,
  tape,
  tapeCell,
  tapeCurrent,
  tapeCellIndex,
  tapeCellValue,
} = require('../../scss/components/tape.scss');

const Tape = ({currentPointer, memory}) => (
  <div className={tapeContainer}>
    <div className={tape}>
      {(memory || []).map((cell, index) => (
        <div key={index} className={tapeCell}>
          <div className={tapeCellIndex}>
            {index}
          </div>
          <div className={classNames({
            [tapeCellValue]: true,
            [tapeCurrent]: index === currentPointer,
          })}>
            {cell}
          </div>
        </div>
      ))}
    </div>
  </div>
);

Tape.propTypes = {
  children: React.PropTypes.any,
  className: React.PropTypes.string,
};

module.exports = Tape;<commit_msg>Displaying the cell char as well as the value and index<commit_after>const React = require('react');
const classNames = require('classnames');

const {
  tapeContainer,
  tape,
  tapeCell,
  tapeCurrent,
  tapeCellIndex,
  tapeCellValue,
} = require('../../scss/components/tape.scss');

const Tape = ({currentPointer, memory}) => (
  <div className={tapeContainer}>
    <div className={tape}>
      {(memory || []).map((cell, index) => (
        <div key={index} className={tapeCell}>
          <div className={tapeCellIndex}>
            {index}
          </div>
          <div className={tapeCellIndex}>
            <code>'{
              String.fromCharCode(cell)
                .replace('\n', '\\n')
                .replace('\t', '\\t')
                .replace('\b', '\\b')
                .replace('\r', '\\r')
                .replace('\r', '\\r')
                .replace('\v', '\\v')
            }'</code>
          </div>
          <div className={classNames({
            [tapeCellValue]: true,
            [tapeCurrent]: index === currentPointer,
          })}>
            {cell}
          </div>
        </div>
      ))}
    </div>
  </div>
);

Tape.propTypes = {
  children: React.PropTypes.any,
  className: React.PropTypes.string,
};

module.exports = Tape;
{'fraction_non_alphanumeric': 0.17570093457943925, 'fraction_numerical': 0.0, 'mean_word_length': 2.0325779036827196, 'pattern_counts': {'":': 0, '<': 27, '<?xml version=': 0, '>': 31, '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': '2130092', 'n_tokens_mistral': 663, 'n_tokens_neox': 668, 'n_words': 129}