Chromium Code Reviews| Index: Source/wtf/Alias.h |
| diff --git a/Source/wtf/Alias.h b/Source/wtf/Alias.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..cc0ed6efeaab0240b96b95fe7e3b09c2045684f1 |
| --- /dev/null |
| +++ b/Source/wtf/Alias.h |
| @@ -0,0 +1,19 @@ |
| +// Copyright (c) 2011 The Chromium Authors. All rights reserved. |
|
haraken
2015/09/04 05:22:45
2015
tasak
2015/09/04 06:12:06
Since I copied //base/debug/alias.h, I think, we s
|
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef Alias_h |
| +#define Alias_h |
| + |
| +#include "wtf/WTFExport.h" |
| + |
| +namespace WTF { |
| + |
| +// Make the optimizer think that var is aliased. This is to prevent it from |
| +// optimizing out variables that that would not otherwise be live at the point |
|
haraken
2015/09/04 05:22:45
that that
tasak
2015/09/04 06:12:06
Done.
|
| +// of a potential crash. |
| +void WTF_EXPORT alias(const void* var); |
|
haraken
2015/09/04 05:22:45
Shall we add this to Compiler.h instead of introdu
tasak
2015/09/04 06:12:06
So we will add Compiler.cpp?
|
| + |
| +} // namespace WTF |
| + |
| +#endif // Alias_h |