From f17e20d5fefeb9ce30a08e85c10b9449cf672112 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Mon, 14 Dec 2015 18:10:25 -0700 Subject: instead of *mut and *const, & and &const closes #33 --- src/parseh.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/parseh.cpp') diff --git a/src/parseh.cpp b/src/parseh.cpp index 6dc9972415..1e931681ce 100644 --- a/src/parseh.cpp +++ b/src/parseh.cpp @@ -250,9 +250,9 @@ static Buf *to_zig_type(ParseH *p, CXType raw_type) { CXType pointee_type = clang_getArrayElementType(raw_type); Buf *pointee_buf = to_zig_type(p, pointee_type); if (clang_isConstQualifiedType(pointee_type)) { - return buf_sprintf("*const %s", buf_ptr(pointee_buf)); + return buf_sprintf("&const %s", buf_ptr(pointee_buf)); } else { - return buf_sprintf("*mut %s", buf_ptr(pointee_buf)); + return buf_sprintf("&%s", buf_ptr(pointee_buf)); } } case CXType_Pointer: @@ -265,9 +265,9 @@ static Buf *to_zig_type(ParseH *p, CXType raw_type) { pointee_buf = to_zig_type(p, pointee_type); } if (clang_isConstQualifiedType(pointee_type)) { - return buf_sprintf("*const %s", buf_ptr(pointee_buf)); + return buf_sprintf("&const %s", buf_ptr(pointee_buf)); } else { - return buf_sprintf("*mut %s", buf_ptr(pointee_buf)); + return buf_sprintf("&%s", buf_ptr(pointee_buf)); } } case CXType_Record: -- cgit v1.2.3