Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/bvt-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ jobs:
cat <<EOF > benchmarking-report.md
# Benchmarking Report

- Generated for: [Microsoft "Proxy" library](https://github.com/microsoft/proxy)
- Commit ID: [${{ github.sha }}](https://github.com/microsoft/proxy/commit/${{ github.sha }})
- Generated for: [C++ Proxy library](https://github.com/ngcpp/proxy)
- Commit ID: [${{ github.sha }}](https://github.com/ngcpp/proxy/commit/${{ github.sha }})
- Generated at: $(date -u +"%Y-%m-%dT%H:%M:%SZ")

EOF
Expand Down
10 changes: 5 additions & 5 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Microsoft Open Source Code of Conduct
# Next Gen C++ Foundation Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
This project has adopted the [Contributor Covenant Code of Conduct](https://www.contributor-covenant.org/version/2/1/code_of_conduct/).

Resources:

- [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
- [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
- Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
- [Contributor Covenant Code of Conduct](https://www.contributor-covenant.org/version/2/1/code_of_conduct/)
- [Contributor Covenant FAQ](https://www.contributor-covenant.org/faq/)
- Contact [conduct@ngcpp.org](mailto:conduct@ngcpp.org) with questions or concerns
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) Microsoft Corporation.
Copyright (c) 2022-2026 Microsoft Corporation.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
106 changes: 47 additions & 59 deletions README.md

Large diffs are not rendered by default.

40 changes: 12 additions & 28 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,25 @@
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.7 BLOCK -->

## Security

Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).

If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://aka.ms/opensource/security/definition), please report it to us as described below.
The Next Gen C++ Foundation (ngcpp) takes security seriously. If you believe you have found a security vulnerability in this repository, please report it responsibly.

## Reporting Security Issues

**Please do not report security vulnerabilities through public GitHub issues.**

Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://aka.ms/opensource/security/create-report).

If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://aka.ms/opensource/security/pgpkey).

You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://aka.ms/opensource/security/msrc).

Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:

* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
* Full paths of source file(s) related to the manifestation of the issue
* The location of the affected source code (tag/branch/commit or direct URL)
* Any special configuration required to reproduce the issue
* Step-by-step instructions to reproduce the issue
* Proof-of-concept or exploit code (if possible)
* Impact of the issue, including how an attacker might exploit the issue

This information will help us triage your report more quickly.
Instead, please create a private security advisory at:

If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://aka.ms/opensource/security/bounty) page for more details about our active programs.
- https://github.com/ngcpp/proxy/security/advisories/new

## Preferred Languages
If you need to share additional details that do not fit in the advisory, you may email:

We prefer all communications to be in English.
- ngcpp@outlook.com

## Policy
Please include as much of the following as possible to help us triage quickly:

Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://aka.ms/opensource/security/cvd).
- Type of issue (e.g., buffer overflow, RCE, etc.)
- Affected file paths and versions/commits
- Reproduction steps and any required configuration
- Proof-of-concept (if available)
- Impact assessment

<!-- END MICROSOFT SECURITY.MD BLOCK -->
We aim to acknowledge reports within 72 hours.
27 changes: 9 additions & 18 deletions SUPPORT.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,16 @@
# TODO: The maintainer of this repo has not yet edited this file

**REPO OWNER**: Do you want Customer Service & Support (CSS) support for this product/project?

- **No CSS support:** Fill out this template with information about how to file issues and get help.
- **Yes CSS support:** Fill out an intake form at [aka.ms/onboardsupport](https://aka.ms/onboardsupport). CSS will work with/help you to determine next steps.
- **Not sure?** Fill out an intake as though the answer were "Yes". CSS will help you decide.

*Then remove this first heading from this SUPPORT.MD file before publishing your repo.*

# Support

## How to file issues and get help

This project uses GitHub Issues to track bugs and feature requests. Please search the existing
issues before filing new issues to avoid duplicates. For new issues, file your bug or
feature request as a new Issue.
This project uses GitHub Issues to track bugs and feature requests. Please search the existing
issues before filing new ones to avoid duplicates. For new issues, file your bug or feature request
as a new issue.

For help and questions about using this project, please use GitHub Discussions:

For help and questions about using this project, please **REPO MAINTAINER: INSERT INSTRUCTIONS HERE
FOR HOW TO ENGAGE REPO OWNERS OR COMMUNITY FOR HELP. COULD BE A STACK OVERFLOW TAG OR OTHER
CHANNEL. WHERE WILL YOU HELP PEOPLE?**.
- https://github.com/ngcpp/proxy/discussions

## Microsoft Support Policy
## Support Policy

Support for this **PROJECT or PRODUCT** is limited to the resources listed above.
Support for this project is provided on a best-effort basis by the community and maintainers via
the resources listed above.
2 changes: 1 addition & 1 deletion benchmarks/proxy_creation_benchmark.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <any>
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/proxy_operation_benchmark.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <benchmark/benchmark.h>
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/proxy_operation_benchmark_context.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include "proxy_operation_benchmark_context.h"
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/proxy_operation_benchmark_context.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <any>
Expand Down
6 changes: 3 additions & 3 deletions docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

### <a name="why-popular">Why is "Proxy" so popular?</a>

"Proxy" is built by engineers at Microsoft and initially deployed in the Windows operating system. For 40 years, the inheritance-based polymorphism paradigm has been the only scalable solution for runtime polymorphism in C++. However, a "virtual function" is no longer the optimal choice for runtime polymorphism today, and new languages with better paradigms, like [traits in Rust](https://doc.rust-lang.org/book/ch10-02-traits.html), are emerging. "Proxy" is our latest and greatest solution for generic runtime polymorphism in C++. It is easy to integrate and makes C++ feel like a brand new language when dealing with runtime abstractions.
"Proxy" was created by Microsoft engineers and incubated at Microsoft from 2018 to Feb 2026, has been used in the Windows operating system since 2022. It is now maintained by the Next Gen C++ Foundation (ngcpp). For 40 years, the inheritance-based polymorphism paradigm has been the only scalable solution for runtime polymorphism in C++. However, a "virtual function" is no longer the optimal choice for runtime polymorphism today, and new languages with better paradigms, like [traits in Rust](https://doc.rust-lang.org/book/ch10-02-traits.html), are emerging. "Proxy" is our latest and greatest solution for generic runtime polymorphism in C++. It is easy to integrate and makes C++ feel like a brand new language when dealing with runtime abstractions.
Copy link

Copilot AI Jan 29, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is an inconsistency in comma placement compared to the FAQ. In the FAQ (line 24), the text reads "from 2018 to Feb 2026, has been" without "and", while in README (line 19) it reads "from 2018 to Feb 2026, and has been". These should be consistent. The README version with "and" is grammatically more correct.

Suggested change
"Proxy" was created by Microsoft engineers and incubated at Microsoft from 2018 to Feb 2026, has been used in the Windows operating system since 2022. It is now maintained by the Next Gen C++ Foundation (ngcpp). For 40 years, the inheritance-based polymorphism paradigm has been the only scalable solution for runtime polymorphism in C++. However, a "virtual function" is no longer the optimal choice for runtime polymorphism today, and new languages with better paradigms, like [traits in Rust](https://doc.rust-lang.org/book/ch10-02-traits.html), are emerging. "Proxy" is our latest and greatest solution for generic runtime polymorphism in C++. It is easy to integrate and makes C++ feel like a brand new language when dealing with runtime abstractions.
"Proxy" was created by Microsoft engineers and incubated at Microsoft from 2018 to Feb 2026, and has been used in the Windows operating system since 2022. It is now maintained by the Next Gen C++ Foundation (ngcpp). For 40 years, the inheritance-based polymorphism paradigm has been the only scalable solution for runtime polymorphism in C++. However, a "virtual function" is no longer the optimal choice for runtime polymorphism today, and new languages with better paradigms, like [traits in Rust](https://doc.rust-lang.org/book/ch10-02-traits.html), are emerging. "Proxy" is our latest and greatest solution for generic runtime polymorphism in C++. It is easy to integrate and makes C++ feel like a brand new language when dealing with runtime abstractions.

Copilot uses AI. Check for mistakes.

### <a name="who-for">Who is "Proxy" for?</a>

Expand All @@ -37,7 +37,7 @@ The fundamental abstraction of "Proxy" is called "facade". It is recommended for

### <a name="how-integrate">How to integrate "Proxy" into my project?</a>

Since "Proxy" is a header-only library, you can simply navigate to the [latest release](https://github.com/microsoft/proxy/releases), download the source code, and include "proxy.h" in your project. Make sure your compiler version meets the [minimum requirements for compilers](README.md#minimum-requirements-for-compilers). If your project has already integrated with [vcpkg](https://vcpkg.io/) or [conan](https://conan.io/), just search for the keyword "proxy" and install it. Thanks to the community that helped port "Proxy" to these platforms!
Since "Proxy" is a header-only library, you can simply navigate to the [latest release](https://github.com/ngcpp/proxy/releases), download the source code, and include "proxy.h" in your project. Make sure your compiler version meets the [minimum requirements for compilers](README.md#minimum-requirements-for-compilers). If your project has already integrated with [vcpkg](https://vcpkg.io/) or [conan](https://conan.io/), just search for the keyword "proxy" and install it. Thanks to the community that helped port "Proxy" to these platforms!

### <a name="how-migrate">My existing project uses virtual functions. How should I migrate to "Proxy"?</a>

Expand Down Expand Up @@ -92,4 +92,4 @@ These rules let old and new code coexist during the transition while keeping ODR

### <a name="help-needed">What should I do if I found this library deficient in my scenario?</a>

Please search for your scenario in the existing issues first, and feel free to file an a new one on demand, following the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
Please search for your scenario in the existing issues first, and feel free to file an a new one on demand, following the [Contributor Covenant Code of Conduct](https://www.contributor-covenant.org/version/2/1/code_of_conduct/).
Binary file modified docs/resources/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion include/proxy/proxy.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef MSFT_PROXY_PROXY_H_
Expand Down
2 changes: 1 addition & 1 deletion include/proxy/proxy_fmt.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef MSFT_PROXY_PROXY_FMT_H_
Expand Down
2 changes: 1 addition & 1 deletion include/proxy/proxy_macros.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef MSFT_PROXY_PROXY_MACROS_H_
Expand Down
2 changes: 1 addition & 1 deletion include/proxy/v4/proxy.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef MSFT_PROXY_V4_PROXY_H_
Expand Down
2 changes: 1 addition & 1 deletion include/proxy/v4/proxy_fmt.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef MSFT_PROXY_V4_PROXY_FMT_H_
Expand Down
2 changes: 1 addition & 1 deletion include/proxy/v4/proxy_macros.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef MSFT_PROXY_V4_PROXY_MACROS_H_
Expand Down
2 changes: 1 addition & 1 deletion meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ if pkgconfig.found()
pkgconfig.generate(
name: meson.project_name(),
description: 'Next Generation Polymorphism in C++',
url: 'https://microsoft.github.io/proxy/',
url: 'https://ngcpp.github.io/proxy/',
)
endif

Expand Down
6 changes: 3 additions & 3 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
---
site_name: Proxy 4
site_url: https://microsoft.github.io/proxy
site_url: https://ngcpp.github.io/proxy
site_description: Next Generation Polymorphism in C++
copyright: Copyright (c) Microsoft Corporation
repo_url: https://github.com/microsoft/proxy/
copyright: Copyright (c) 2022-2026 Microsoft Corporation
repo_url: https://github.com/ngcpp/proxy/
edit_uri: ""

theme:
Expand Down
2 changes: 1 addition & 1 deletion mkdocs/overrides/main.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
c[a]=c[a]||function(){(c[a].q=c[a].q||[]).push(arguments)};
t=l.createElement(r);t.async=1;t.src="https://www.clarity.ms/tag/"+i;
y=l.getElementsByTagName(r)[0];y.parentNode.insertBefore(t,y);
})(window, document, "clarity", "script", "roby7oe11n");
})(window, document, "clarity", "script", "v8vxusocp2");
</script>
{% endblock %}
2 changes: 1 addition & 1 deletion tests/proxy_creation_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include "utils.h"
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_dispatch_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <gtest/gtest.h>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_fmt_format_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <gtest/gtest.h>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_format_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <gtest/gtest.h>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_integration_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <gtest/gtest.h>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_invocation_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <algorithm>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_lifetime_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include "utils.h"
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_reflection_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include "utils.h"
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_regression_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <gtest/gtest.h>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_rtti_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <gtest/gtest.h>
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_traits_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include "utils.h"
Expand Down
2 changes: 1 addition & 1 deletion tests/proxy_view_tests.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include "utils.h"
Expand Down
2 changes: 1 addition & 1 deletion tests/utils.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#ifndef _MSFT_PROXY_TEST_UTILS_
Expand Down
2 changes: 1 addition & 1 deletion tools/report_generator/main.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation.
// Copyright (c) 2022-2026 Microsoft Corporation.
// Licensed under the MIT License.

#include <cstdio>
Expand Down