当前位置: 首页>>代码示例>>C++>>正文


C++ DIBuilder::createPointerType方法代码示例

本文整理汇总了C++中DIBuilder::createPointerType方法的典型用法代码示例。如果您正苦于以下问题:C++ DIBuilder::createPointerType方法的具体用法?C++ DIBuilder::createPointerType怎么用?C++ DIBuilder::createPointerType使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DIBuilder的用法示例。


在下文中一共展示了DIBuilder::createPointerType方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: sizeof

int
DefinePointerType(
    ClientData clientData,
    Tcl_Interp *interp,
    int objc,
    Tcl_Obj *const objv[])
{
    if (objc != 3) {
	Tcl_WrongNumArgs(interp, 1, objv, "DIBuilder pointee");
	return TCL_ERROR;
    }

    DIBuilder *builder;
    if (GetDIBuilderFromObj(interp, objv[1], builder) != TCL_OK)
	return TCL_ERROR;
    DIType *pointee;
    if (GetMetadataFromObj(interp, objv[2], "type", pointee) != TCL_OK)
	return TCL_ERROR;
    size_t size = sizeof(pointee) * 8;

    auto val = builder->createPointerType(pointee, size);

    Tcl_SetObjResult(interp, NewMetadataObj(val, "PointerType"));
    return TCL_OK;
}
开发者ID:jdc8,项目名称:llvmtcl,代码行数:25,代码来源:debuginfo.cpp

示例2: LLVMDIBuilderCreatePointerType

LLVMMetadataRef LLVMDIBuilderCreatePointerType(LLVMDIBuilderRef Dref,
                                               LLVMMetadataRef PointeeType,
                                               uint64_t SizeInBits,
                                               uint32_t AlignInBits,
                                               const char *Name) {
  DIBuilder *D = unwrap(Dref);
  return wrap(D->createPointerType(unwrap<DIType>(PointeeType), SizeInBits,
                                   AlignInBits, Name));
}
开发者ID:1995hnagamin,项目名称:llvm,代码行数:9,代码来源:DIBuilderBindings.cpp

示例3: LLVMDIBuilderCreatePointerType

LLVMValueRef LLVMDIBuilderCreatePointerType(LLVMDIBuilderRef Dref,
                                            LLVMValueRef PointeeType,
                                            uint64_t SizeInBits,
                                            uint64_t AlignInBits,
                                            const char *Name) {
  DIBuilder *D = unwrap(Dref);
  DIDerivedType T = D->createPointerType(unwrapDI<DIType>(PointeeType),
                                         SizeInBits, AlignInBits, Name);
  return wrap(T);
}
开发者ID:Drup,项目名称:llvm,代码行数:10,代码来源:DIBuilderBindings.cpp

示例4: DIBuilderCreatePointerType

LLVMValueRef DIBuilderCreatePointerType(LLVMDIBuilderRef dref,
                                        LLVMValueRef pointeeType,
                                        uint64_t sizeInBits,
                                        uint64_t alignInBits,
                                        const char *name) {
  DIBuilder *d = unwrap(dref);
  DIDerivedType t = d->createPointerType(
      unwrapDI<DIType>(pointeeType), sizeInBits, alignInBits, StringRef(name));
  return wrap(t);
}
开发者ID:go-llvm,项目名称:llvm,代码行数:10,代码来源:dibuilder.cpp


注:本文中的DIBuilder::createPointerType方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。