Unverified Commit d15e9b6a authored by K900's avatar K900 Committed by GitHub
Browse files

Revert "nixos-option: cleanup and linting" (#363919)

parents 2eccf312 ba8c0432
Loading
Loading
Loading
Loading
+0 −26
Original line number Diff line number Diff line
Checks:
- bugprone-*
# don't find them too problematic
- -bugprone-easily-swappable-parameters
- performance-*
- modernize-*
# doesn't improve readability much in this project
- -modernize-use-trailing-return-type
- readability-*
# don't find them too problematic
- -readability-identifier-length
- -readability-magic-numbers
- portability-*
- concurrency-*
- google-*
- -google-readability-todo
- misc-*
# we maybe want to address this?
- -misc-no-recursion
- cppcoreguidelines-*
- -cppcoreguidelines-avoid-magic-numbers
# We could use std::reference_wrapper, but it's not super important
- -cppcoreguidelines-avoid-const-or-ref-data-members
UseColor: true
CheckOptions:
  misc-non-private-member-variables-in-classes.IgnoreClassesWithAllMemberVariablesBeingPublic: True
+0 −1
Original line number Diff line number Diff line
use nix
+0 −7
Original line number Diff line number Diff line
with import ../../../.. { };
nixos-option.overrideAttrs (old: {
  nativeBuildInputs = old.nativeBuildInputs ++ [
    # hiprio so that it has a higher priority than the default unwrapped clang tools from clang if our stdenv is based on clang
    (lib.hiPrio pkgs.buildPackages.clang-tools)
  ];
})
+2 −5
Original line number Diff line number Diff line
@@ -2,13 +2,11 @@
// Since they are not, copy/paste them here.
// TODO: Delete these and use the ones in the library as they become available.

#include <string_view>
#include "libnix-copy-paste.hh"
#include <nix/print.hh>
#include <nix/print.hh>                           // for Strings

// NOLINTBEGIN
// From nix/src/nix/repl.cc
bool isVarName(std::string_view s)
bool isVarName(const std::string_view & s)
{
    if (s.size() == 0) return false;
    if (nix::isReservedKeyword(s)) return false;
@@ -22,4 +20,3 @@ bool isVarName(std::string_view s)
            return false;
    return true;
}
// NOLINTEND
+2 −2
Original line number Diff line number Diff line
#pragma once

#include <string_view>
#include <nix/types.hh>

bool isVarName(std::string_view s);
bool isVarName(const std::string_view & s);
Loading