From b174a7c21793ed8bac8ec7ff7db696aa38370f4c Mon Sep 17 00:00:00 2001 From: Dave Kwon Date: Mon, 9 Dec 2024 00:06:31 -0800 Subject: [PATCH] Disable @python.Py3EnableCppAdapter for typedef resolving to primitive and structs Summary: Initial use cases seems like mostly containers, binary, and string. Let's restrict it. Reviewed By: createdbysk Differential Revision: D66511516 fbshipit-source-id: a10f50de4b23b779948078c048c397449993f951 --- thrift/annotation/python.thrift | 1 + 1 file changed, 1 insertion(+) diff --git a/thrift/annotation/python.thrift b/thrift/annotation/python.thrift index 3de4736c6..69c362737 100644 --- a/thrift/annotation/python.thrift +++ b/thrift/annotation/python.thrift @@ -97,5 +97,6 @@ struct UseCAPI { } /// Enables C++ Adapter for thrift-py3. It treats C++ Adapter on typedef as cpp.Type. +/// It is only available for typedefs that resolve to binary, string, and container type. @scope.Typedef struct Py3EnableCppAdapter {}