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

Side by Side Diff: runtime/vm/memory_region.cc

Issue 2481873005: clang-format runtime/vm (Closed)
Patch Set: Merge Created 4 years, 1 month 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 | « runtime/vm/memory_region.h ('k') | runtime/vm/message.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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/memory_region.h" 5 #include "vm/memory_region.h"
6 6
7 namespace dart { 7 namespace dart {
8 8
9 void MemoryRegion::CopyFrom(uword offset, const MemoryRegion& from) const { 9 void MemoryRegion::CopyFrom(uword offset, const MemoryRegion& from) const {
10 ASSERT(from.pointer() != NULL && from.size() > 0); 10 ASSERT(from.pointer() != NULL && from.size() > 0);
11 ASSERT(this->size() >= from.size()); 11 ASSERT(this->size() >= from.size());
12 ASSERT(offset <= this->size() - from.size()); 12 ASSERT(offset <= this->size() - from.size());
13 memmove(reinterpret_cast<void*>(start() + offset), 13 memmove(reinterpret_cast<void*>(start() + offset), from.pointer(),
14 from.pointer(), from.size()); 14 from.size());
15 } 15 }
16 16
17 } // namespace dart 17 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/memory_region.h ('k') | runtime/vm/message.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698