You've already forked linux-packaging-mono
acceptance-tests
data
debian
docs
external
Newtonsoft.Json
api-doc-tools
api-snapshot
aspnetwebstack
bdwgc
binary-reference-assemblies
bockbuild
boringssl
cecil
cecil-legacy
corefx
corert
helix-binaries
ikdasm
ikvm
illinker-test-assets
linker
llvm-project
clang
clang-tools-extra
change-namespace
clang-apply-replacements
clang-move
clang-query
clang-reorder-fields
clang-tidy
clang-tidy-vs
clangd
docs
include-fixer
modularize
pp-trace
test
Unit
change-namespace
Inputs
lambda-function.cpp
macro.cpp
simple-move.cpp
white-list.cpp
clang-apply-replacements
clang-move
clang-query
clang-reorder-fields
clang-tidy
clangd
include-fixer
modularize
pp-trace
.clang-format
CMakeLists.txt
lit.cfg
lit.site.cfg.in
tool-template
unittests
.arcconfig
.gitignore
CMakeLists.txt
CODE_OWNERS.TXT
LICENSE.TXT
README.txt
compiler-rt
eng
libcxx
libcxxabi
libunwind
lld
lldb
llvm
nuget
openmp
polly
Directory.Build.props
Directory.Build.targets
NuGet.config
azure-pipelines.yml
build.cmd
build.sh
dir.common.props
global.json
llvm.proj
mxe-Win64.cmake.in
nuget-buildtasks
nunit-lite
roslyn-binaries
rx
xunit-binaries
how-to-bump-roslyn-binaries.md
ikvm-native
llvm
m4
man
mcs
mono
msvc
netcore
po
runtime
samples
scripts
support
tools
COPYING.LIB
LICENSE
Makefile.am
Makefile.in
NEWS
README.md
acinclude.m4
aclocal.m4
autogen.sh
code_of_conduct.md
compile
config.guess
config.h.in
config.rpath
config.sub
configure.REMOVED.git-id
configure.ac.REMOVED.git-id
depcomp
install-sh
ltmain.sh.REMOVED.git-id
missing
mkinstalldirs
mono-uninstalled.pc.in
test-driver
winconfig.h
38 lines
938 B
C++
38 lines
938 B
C++
![]() |
// RUN: clang-change-namespace -old_namespace "na::nb" -new_namespace "x::y" --file_pattern ".*" %s -- -std=c++11 | sed 's,// CHECK.*,,' | FileCheck %s
|
||
|
|
||
|
template <class T>
|
||
|
class function;
|
||
|
template <class R, class... ArgTypes>
|
||
|
class function<R(ArgTypes...)> {
|
||
|
public:
|
||
|
template <typename Functor>
|
||
|
function(Functor f) {}
|
||
|
R operator()(ArgTypes...) const {}
|
||
|
};
|
||
|
|
||
|
namespace x {
|
||
|
// CHECK: namespace x {
|
||
|
class X {};
|
||
|
}
|
||
|
|
||
|
namespace na {
|
||
|
namespace nb {
|
||
|
// CHECK: namespace x {
|
||
|
// CHECK-NEXT: namespace y {
|
||
|
void f(function<void(int)> func, int param) { func(param); }
|
||
|
void g() { f([](int x) {}, 1); }
|
||
|
|
||
|
// x::X in function type parameter list will have translation unit context, so
|
||
|
// we simply replace it with fully-qualified name.
|
||
|
using TX = function<x::X(x::X)>;
|
||
|
// CHECK: using TX = function<X(x::X)>;
|
||
|
|
||
|
class A {};
|
||
|
using TA = function<A(A)>;
|
||
|
// CHECK: using TA = function<A(A)>;
|
||
|
|
||
|
// CHECK: } // namespace y
|
||
|
// CHECK-NEXT: } // namespace x
|
||
|
}
|
||
|
}
|