Пример #1
0
        internal static BitcodeModule FromHandle(LLVMModuleRef nativeHandle)
        {
            nativeHandle.ValidateNotDefault(nameof(nativeHandle));
            var context = nativeHandle.Context;

            return(context.GetModuleFor(nativeHandle));
        }
Пример #2
0
        internal BitcodeModule(LLVMModuleRef handle)
        {
            handle.ValidateNotDefault(nameof(handle));

            ModuleHandle  = handle;
            LazyDiBuilder = new Lazy <DebugInfoBuilder>(() => new DebugInfoBuilder(this));
            Context.AddModule(this);
            Comdats = new ComdatCollection(this);
        }