Skip to content

Commit d9bbad2

Browse files
author
Siva Chandra Reddy
committed
[libc][Obvious][NFC] A bunch of cosmetic cleanup.
* Added missing header guards. * Fixed license header format in a few files. * Renamed files to more suitable names.
1 parent f3b7cc8 commit d9bbad2

File tree

9 files changed

+26
-6
lines changed

9 files changed

+26
-6
lines changed

libc/fuzzing/math/RemQuoDiff.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
//
77
//===----------------------------------------------------------------------===//
88

9+
#ifndef LLVM_LIBC_FUZZING_MATH_REMQUO_H
10+
#define LLVM_LIBC_FUZZING_MATH_REMQUO_H
11+
912
#include "src/__support/FPUtil/FPBits.h"
1013

1114
#include <math.h>
@@ -46,3 +49,5 @@ void RemQuoDiff(RemQuoFunc<T> func1, RemQuoFunc<T> func2, const uint8_t *data,
4649
if (bits1.uintval() != bits2.uintval())
4750
__builtin_trap();
4851
}
52+
53+
#endif // LLVM_LIBC_FUZZING_MATH_REMQUO_H

libc/fuzzing/stdlib/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ add_libc_fuzzer(
77
)
88

99
add_libc_fuzzer(
10-
atof_fuzz
10+
atof_differential_fuzz
1111
SRCS
12-
atof_fuzz.cpp
12+
atof_differential_fuzz.cpp
1313
HDRS
1414
StringParserOutputDiff.h
1515
DEPENDS
File renamed without changes.

libc/include/sys/mman.h.def

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@
66
//
77
//===----------------------------------------------------------------------===//
88

9+
#ifndef LLVM_LIBC_SYS_MMAN_H
10+
#define LLVM_LIBC_SYS_MMAN_H
11+
912
#include <__llvm-libc-common.h>
1013

1114
%%public_api()
15+
16+
#endif // LLVM_LIBC_SYS_MMAN_H

libc/include/sys/syscall.h.def

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@
66
//
77
//===----------------------------------------------------------------------===//
88

9+
#ifndef LLVM_LIBC_SYS_SYSCALL_H
10+
#define LLVM_LIBC_SYS_SYSCALL_H
11+
912
<!> If syscall.h were a linux only file, then we do not need this indirection.
1013
<!> However, to keep the option of a non-linux OS requiring a syscall.h file,
1114
<!> with its own special syscall numbers, we use this indirection.
1215
%%include_file(${syscall_numbers})
16+
17+
#endif // LLVM_LIBC_SYS_SYSCALL_H

libc/src/__support/architectures.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
1-
//===-- Compile time architecture detection -------------------------------===//
1+
//===-- Compile time architecture detection ---------------------*- C++ -*-===//
22
//
33
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
44
// See https://llvm.org/LICENSE.txt for license information.
55
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
66
//
77
//===----------------------------------------------------------------------===//
88

9+
#ifndef LLVM_LIBC_SUPPORT_ARCHITECTURES_H
10+
#define LLVM_LIBC_SUPPORT_ARCHITECTURES_H
11+
912
#if defined(__pnacl__) || defined(__CLR_VER)
1013
#define LLVM_LIBC_ARCH_VM
1114
#endif
@@ -33,3 +36,5 @@
3336
#if (defined(LLVM_LIBC_ARCH_AARCH64) || defined(LLVM_LIBC_ARCH_ARM))
3437
#define LLVM_LIBC_ARCH_ANY_ARM
3538
#endif
39+
40+
#endif // LLVM_LIBC_SUPPORT_ARCHITECTURES_H

libc/src/__support/common.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//===-- Common internal contructs -----------------------------------------===//
1+
//===-- Common internal contructs -------------------------------*- C++ -*-===//
22
//
33
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
44
// See https://llvm.org/LICENSE.txt for license information.

libc/src/__support/endian.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//===-- Endianness support ------------------------------------------------===//
1+
//===-- Endianness support --------------------------------------*- C++ -*-===//
22
//
33
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
44
// See https://llvm.org/LICENSE.txt for license information.

libc/src/__support/sanitizer.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//===-- Convenient sanitizer macros ---------------------------------------===//
1+
//===-- Convenient sanitizer macros -----------------------------*- C++ -*-===//
22
//
33
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
44
// See https://llvm.org/LICENSE.txt for license information.

0 commit comments

Comments
 (0)