<commit_before>{ stdenv, fetchFromGitHub, cmake
, hostPlatform
}:

stdenv.mkDerivation rec {
  name = "nlohmann_json-${version}";
  version = "3.1.2";

  src = fetchFromGitHub {
    owner = "nlohmann";
    repo = "json";
    rev = "v${version}";
    sha256 = "1mpr781fb2dfbyscrr7nil75lkxsazg4wkm749168lcf2ksrrbfi";
  };

  nativeBuildInputs = [ cmake ];

  enableParallelBuilding = true;

  cmakeFlags = [
    "-DBuildTests=${if doCheck then "ON" else "OFF"}"
  ] ++ stdenv.lib.optionals (hostPlatform.libc == "msvcrt") [
    "-DCMAKE_SYSTEM_NAME=Windows"
  ];

  doCheck = stdenv.hostPlatform == stdenv.buildPlatform;

  meta = with stdenv.lib; {
    description = "Header only C++ library for the JSON file format";
    homepage = https://github.com/nlohmann/json;
    license = licenses.mit;
    platforms = platforms.all;
  };
}<commit_msg>nlohmann_json: 3.1.2 -> 3.2.0 (#45559)<commit_after>{ stdenv, fetchFromGitHub, cmake
, hostPlatform
}:

stdenv.mkDerivation rec {
  name = "nlohmann_json-${version}";
  version = "3.2.0";

  src = fetchFromGitHub {
    owner = "nlohmann";
    repo = "json";
    rev = "v${version}";
    sha256 = "0585r6ai9x1bhspffn5w5620wxfl1q1gj476brsnaf7wwnr60hwk";
  };

  nativeBuildInputs = [ cmake ];

  enableParallelBuilding = true;

  cmakeFlags = [
    "-DBuildTests=${if doCheck then "ON" else "OFF"}"
  ] ++ stdenv.lib.optionals (hostPlatform.libc == "msvcrt") [
    "-DCMAKE_SYSTEM_NAME=Windows"
  ];

  doCheck = stdenv.hostPlatform == stdenv.buildPlatform;

  meta = with stdenv.lib; {
    description = "Header only C++ library for the JSON file format";
    homepage = https://github.com/nlohmann/json;
    license = licenses.mit;
    platforms = platforms.all;
  };
}
{'fraction_non_alphanumeric': 0.14477524810274373, 'fraction_numerical': 0.034442498540572096, 'mean_word_length': 3.6324324324324326, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 2, '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': '6535870', 'n_tokens_mistral': 691, 'n_tokens_neox': 639, 'n_words': 119}