Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(458)

Side by Side Diff: sandbox/win/src/crosscall_params.h

Issue 821693003: replace COMPILE_ASSERT with static_assert in sandbox/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sandbox/win/src/crosscall_client.h ('k') | sandbox/win/src/policy_engine_opcodes.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef SANDBOX_SRC_CROSSCALL_PARAMS_H__ 5 #ifndef SANDBOX_SRC_CROSSCALL_PARAMS_H__
6 #define SANDBOX_SRC_CROSSCALL_PARAMS_H__ 6 #define SANDBOX_SRC_CROSSCALL_PARAMS_H__
7 7
8 #include <windows.h> 8 #include <windows.h>
9 #include <lmaccess.h> 9 #include <lmaccess.h>
10 10
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 protected: 280 protected:
281 ActualCallParams() : CrossCallParams(0, NUMBER_PARAMS) { } 281 ActualCallParams() : CrossCallParams(0, NUMBER_PARAMS) { }
282 282
283 private: 283 private:
284 ParamInfo param_info_[NUMBER_PARAMS + 1]; 284 ParamInfo param_info_[NUMBER_PARAMS + 1];
285 char parameters_[BLOCK_SIZE - sizeof(CrossCallParams) 285 char parameters_[BLOCK_SIZE - sizeof(CrossCallParams)
286 - sizeof(ParamInfo) * (NUMBER_PARAMS + 1)]; 286 - sizeof(ParamInfo) * (NUMBER_PARAMS + 1)];
287 DISALLOW_COPY_AND_ASSIGN(ActualCallParams); 287 DISALLOW_COPY_AND_ASSIGN(ActualCallParams);
288 }; 288 };
289 289
290 COMPILE_ASSERT(sizeof(ActualCallParams<1, 1024>) == 1024, bad_size_buffer); 290 static_assert(sizeof(ActualCallParams<1, 1024>) == 1024, "bad size buffer");
291 COMPILE_ASSERT(sizeof(ActualCallParams<2, 1024>) == 1024, bad_size_buffer); 291 static_assert(sizeof(ActualCallParams<2, 1024>) == 1024, "bad size buffer");
292 COMPILE_ASSERT(sizeof(ActualCallParams<3, 1024>) == 1024, bad_size_buffer); 292 static_assert(sizeof(ActualCallParams<3, 1024>) == 1024, "bad size buffer");
293 293
294 } // namespace sandbox 294 } // namespace sandbox
295 295
296 #endif // SANDBOX_SRC_CROSSCALL_PARAMS_H__ 296 #endif // SANDBOX_SRC_CROSSCALL_PARAMS_H__
OLDNEW
« no previous file with comments | « sandbox/win/src/crosscall_client.h ('k') | sandbox/win/src/policy_engine_opcodes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698