Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reference returns are broken #50

Closed
Keno opened this issue Dec 24, 2014 · 0 comments
Closed

Reference returns are broken #50

Keno opened this issue Dec 24, 2014 · 0 comments

Comments

@Keno
Copy link
Collaborator

Keno commented Dec 24, 2014

C++ > int &bar(int *foo) {
      return *foo;
      }

C++ > int x = 6;

C++ > bar(&x)
Function return type does not match operand type of return inst!
  ret i32* %call
 i32
define i32 @0() {
top:
  %call = call dereferenceable(4) i32* @_ZN6__icxx5icxx9Ev()
  ret i32* %call
}

ERROR: error compiling anonymous: Malformed LLVM Function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant