Skip to content

Commit

Permalink
Minor formatting cleanups (#1871)
Browse files Browse the repository at this point in the history
A few include order/whitespace fixes that are preventing pre-commit
--all from passing.

b/199280707
  • Loading branch information
kaidokert authored Oct 30, 2023
1 parent 25e3f63 commit ee90c34
Show file tree
Hide file tree
Showing 13 changed files with 23 additions and 22 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1 2 4
1 2 4
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6
6
Original file line number Diff line number Diff line change
@@ -1 +1 @@
-3 10 15
-3 10 15
Original file line number Diff line number Diff line change
@@ -1 +1 @@
-15
-15
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10 -5 -4
10 -5 -4
Original file line number Diff line number Diff line change
@@ -1 +1 @@
-54
-54
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"output": "a_changing_text_file", "patch": "f0", "sha256": "aa607adc0b3cd83e7e9f3ebd4ae84671e2b0b288c9b7fed1e0c710025719caf5", "op": "create"}, {"output": "a_changing_binary_file", "input": "a_changing_binary_file", "patch": "f1", "sha256": "dbd6da0fd6f748b7ec95f0eed6c1f6a046d161bebb04994fe1ce730e237a733d", "op": "bsdiff"}, {"output": "manifest.json", "patch": "f2", "sha256": "1cf8d0b433c09c465994e952a79ff6980c68cc7493609f0233a4634de6276e9c", "op": "create"}, {"output": "a_static_text_file", "input": "a_static_text_file", "sha256": "806bfdfbf05afab546b3741e84fb1ccffdf75eef8629c24c5f84add2785b7bcc", "op": "copy"}]
[{"output": "a_changing_text_file", "patch": "f0", "sha256": "aa607adc0b3cd83e7e9f3ebd4ae84671e2b0b288c9b7fed1e0c710025719caf5", "op": "create"}, {"output": "a_changing_binary_file", "input": "a_changing_binary_file", "patch": "f1", "sha256": "dbd6da0fd6f748b7ec95f0eed6c1f6a046d161bebb04994fe1ce730e237a733d", "op": "bsdiff"}, {"output": "manifest.json", "patch": "f2", "sha256": "1cf8d0b433c09c465994e952a79ff6980c68cc7493609f0233a4634de6276e9c", "op": "create"}, {"output": "a_static_text_file", "input": "a_static_text_file", "sha256": "806bfdfbf05afab546b3741e84fb1ccffdf75eef8629c24c5f84add2785b7bcc", "op": "copy"}]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"sha256": "806bfdfbf05afab546b3741e84fb1ccffdf75eef8629c24c5f84add2785b7bcc", "output": "a_static_text_file", "op": "copy", "input": "a_static_text_file"}, {"sha256": "1cf8d0b433c09c465994e952a79ff6980c68cc7493609f0233a4634de6276e9c", "output": "manifest.json", "op": "create", "patch": "f1"}, {"sha256": "aa607adc0b3cd83e7e9f3ebd4ae84671e2b0b288c9b7fed1e0c710025719caf5", "output": "a_changing_text_file", "op": "create", "patch": "f2"}, {"patch": "f3", "sha256": "dbd6da0fd6f748b7ec95f0eed6c1f6a046d161bebb04994fe1ce730e237a733d", "output": "a_changing_binary_file", "op": "courgette", "input": "a_changing_binary_file"}]
[{"sha256": "806bfdfbf05afab546b3741e84fb1ccffdf75eef8629c24c5f84add2785b7bcc", "output": "a_static_text_file", "op": "copy", "input": "a_static_text_file"}, {"sha256": "1cf8d0b433c09c465994e952a79ff6980c68cc7493609f0233a4634de6276e9c", "output": "manifest.json", "op": "create", "patch": "f1"}, {"sha256": "aa607adc0b3cd83e7e9f3ebd4ae84671e2b0b288c9b7fed1e0c710025719caf5", "output": "a_changing_text_file", "op": "create", "patch": "f2"}, {"patch": "f3", "sha256": "dbd6da0fd6f748b7ec95f0eed6c1f6a046d161bebb04994fe1ce730e237a733d", "output": "a_changing_binary_file", "op": "courgette", "input": "a_changing_binary_file"}]
8 changes: 4 additions & 4 deletions starboard/common/common.cc
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
// These audits are here so they are only displayed once every build.

#if SB_API_VERSION == SB_MAXIMUM_API_VERSION
#pragma message( \
"Your platform's SB_API_VERSION == SB_MAXIMUM_API_VERSION. " \
"You are implementing the Unreleased version of Starboard at your " \
"own risk! We don't recommend this for third parties.")
#pragma message( \
"Your platform's SB_API_VERSION == SB_MAXIMUM_API_VERSION. " \
"You are implementing the Unreleased version of Starboard at your " \
"own risk! We don't recommend this for third parties.")
#endif
6 changes: 3 additions & 3 deletions starboard/common/flat_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@
#ifndef STARBOARD_COMMON_FLAT_MAP_H_
#define STARBOARD_COMMON_FLAT_MAP_H_

#include "starboard/common/log.h"
#include "starboard/types.h"

#include <algorithm>
#include <functional>
#include <utility>
#include <vector>

#include "starboard/common/log.h"
#include "starboard/types.h"

namespace starboard {
namespace flat_map_detail {
// IsPod<> is a white list of common types that are "plain-old-data'.
Expand Down
8 changes: 4 additions & 4 deletions starboard/elf_loader/elf.h
Original file line number Diff line number Diff line change
Expand Up @@ -440,11 +440,11 @@ typedef Elf64_Sword Sword;
#endif

#define ELF32_R_SYM(val) ((val) >> 8)
#define ELF32_R_TYPE(val) ((val)&0xff)
#define ELF32_R_INFO(sym, type) (((sym) << 8) + ((type)&0xff))
#define ELF32_R_TYPE(val) ((val) & 0xff)
#define ELF32_R_INFO(sym, type) (((sym) << 8) + ((type) & 0xff))

#define ELF64_R_SYM(i) ((i) >> 32)
#define ELF64_R_TYPE(i) ((i)&0xffffffff)
#define ELF64_R_TYPE(i) ((i) & 0xffffffff)
#define ELF64_R_INFO(sym, type) ((((Elf64_Xword)(sym)) << 32) + (type))

#define ELFMAG "\177ELF"
Expand Down Expand Up @@ -680,7 +680,7 @@ typedef enum RelocationTypes {
#define PAGE_MASK (~(PAGE_SIZE - 1))
#endif

#define PAGE_START(x) ((x)&PAGE_MASK)
#define PAGE_START(x) ((x) & PAGE_MASK)
#define PAGE_OFFSET(x) ((x) & ~PAGE_MASK)
#define PAGE_END(x) PAGE_START((x) + (PAGE_SIZE - 1))

Expand Down
2 changes: 1 addition & 1 deletion starboard/shared/win32/memory_flush.cc
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include "starboard/common/log.h"
#include "starboard/memory.h"

#include <windows.h>
#include <windows.h> // NOLINT(build/include_order)

#if !SB_CAN(MAP_EXECUTABLE_MEMORY)
#error \
Expand Down
5 changes: 3 additions & 2 deletions starboard/shared/win32/system_symbolize.cc
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@
#include <functional>
#include <string>

#include <Windows.h> // Must go before dbghelp.h
#include <dbghelp.h>
// Must go before dbghelp.h
#include <Windows.h> // NOLINT(build/include_order)
#include <dbghelp.h> // NOLINT(build/include_order)

#include "starboard/common/log.h"
#include "starboard/common/mutex.h"
Expand Down

0 comments on commit ee90c34

Please sign in to comment.