| /* |
| * Copyright (C) 2016 The Android Open Source Project |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| package tests.errors.syntax@1.0; |
| |
| // c++ keyword: error |
| struct asm {}; |
| // java keyword: error |
| struct transient {}; |
| // c++ collide: error |
| struct offsetof {}; |
| struct size_t {}; |
| // hidl names: should warn |
| struct hidl_vec{}; |
| // interface reserved: should be okay |
| struct version{}; |
| |
| interface IIdentifier1 { |
| // c++ keyword: error |
| alignof(); |
| // java keyword: error |
| native(); |
| // c++ collide: error |
| IMPLEMENT_REGISTER_AND_GET_SERVICE(); |
| // interface reserved: should error |
| dump(); |
| // struct reserved: should be okay |
| readEmbeddedFromParcel(); |
| }; |
| |
| struct GoodStruct { |
| // java keyword: error |
| int32_t native; |
| // struct reserved: should error |
| int32_t readEmbeddedFromParcel; |
| // interface reserved: should be okay |
| int32_t dump; |
| }; |