1 /* 2 * Copyright (c) 2023 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef BUILD_RUST_TESTS_BINDGEN_TEST_LIB_H_ 17 #define BUILD_RUST_TESTS_BINDGEN_TEST_LIB_H_ 18 19 // bindgen-flags: --with-derive-hash --with-derive-partialeq --with-derive-eq 20 typedef int SecondInt; 21 22 class C { 23 public: 24 typedef int FirstInt; 25 typedef const char* Lookup; 26 FirstInt c; 27 FirstInt* ptr; 28 FirstInt arr[10]; 29 SecondInt d; 30 SecondInt* other_ptr; 31 32 void method(FirstInt c); 33 void methodRef(FirstInt& c); 34 void complexMethodRef(Lookup& c); 35 void anotherMethod(SecondInt c); 36 }; 37 38 class D : public C { 39 public: 40 FirstInt* ptr; 41 }; 42 43 #endif // BUILD_RUST_TESTS_BINDGEN_TEST_LIB_H_