xref: /aosp_15_r20/external/cronet/build/rust/std/alias.cc (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1 // Copyright 2023 The Chromium Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 // This file has been copied from //base/debug/alias.cc ( additionally the APIs
6 // were moved into the `build_rust_std` namespace).
7 //
8 // TODO(https://crbug.com/1475734): Avoid code duplication / reuse code.
9 
10 #include "build/rust/std/alias.h"
11 
12 #include "build/rust/std/compiler_specific.h"
13 
14 namespace build_rust_std {
15 namespace debug {
16 
17 // This file/function should be excluded from LTO/LTCG to ensure that the
18 // compiler can't see this function's implementation when compiling calls to it.
Alias(const void * var)19 NOINLINE void Alias(const void* var) {}
20 
21 }  // namespace debug
22 }  // namespace build_rust_std
23