Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- extern "C" {
- typedef struct {
- int a;
- } Base;
- typedef struct {
- int a;
- } Derived;
- int Init(Base* b);
- }
- int main() {
- Derived d;
- Init(&d); // compile error: can not convert argument 1 from 'Derived *' to 'Base *'
- }
Add Comment
Please, Sign In to add comment