Skip to content

Instantly share code, notes, and snippets.

@genuinelucifer
Created May 29, 2015 08:07
Show Gist options
  • Save genuinelucifer/9e23701dee397e5c41c3 to your computer and use it in GitHub Desktop.
Save genuinelucifer/9e23701dee397e5c41c3 to your computer and use it in GitHub Desktop.
Trying to regenerate issue when passing a CS_API ptr as CS_OUT!
diff --git a/tests/Basic/Basic.h b/tests/Basic/Basic.h
index 488dd2c..d4d07bd 100644
--- a/tests/Basic/Basic.h
+++ b/tests/Basic/Basic.h
@@ -710,3 +710,21 @@ public:
bool operator ==(const DifferentConstOverloads& other);
bool operator ==(int number) const;
};
+
+#define CS_API
+class CS_API ClassPassTry
+{
+public:
+ int n;
+ char c;
+};
+
+void funcTry(CS_OUT ClassPassTry* classTry)
+{
+
+}
+
+void funcTry2(CS_OUT ClassPassTry classTry)
+{
+
+}
@genuinelucifer
Copy link
Author

Second function generates acceptable code while the first function causes incompilable code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment