Giter VIP home page Giter VIP logo

Comments (1)

dsimcha avatar dsimcha commented on June 3, 2024

Better-reduced test case that doesn't depend on Phobos:

 // figure.d
 import plot2kill.gtkwrapper;

// gtkwrapper.d
void popupTickDialog() {
    toImpl!(double[])(["1.0"]);
}

T toImpl(T)(string[] src) {
    auto result = new double[src.length];
    foreach (e; src)
        result[]= parse!(double)(e);
    return result;
}

Target parse(Target, Source)(ref Source p) {
    Exception bailOut()() {
        return new Exception(text(p));
    }

    bailOut();
    return 0;
}

string text(T...)(T args)  {
    return string.init;
}

$ ldc2 -I.. -O3 figure.d -c
ldc2: /home/dsimcha/ldcStuff/ldc/gen/tollvm.cpp:656: llvm::Value* DtoBitCast(llvm::Value_, llvm::Type_, const char_): Assertion `!isaStruct(t)' failed.
0 ldc2 0x000000000100a78f
1 ldc2 0x000000000100ac79
2 libpthread.so.0 0x00007fb9a7353020
3 libc.so.6 0x00007fb9a643b405 gsignal + 53
4 libc.so.6 0x00007fb9a643e680 abort + 384
5 libc.so.6 0x00007fb9a64345b1 assert_fail + 241
6 ldc2 0x0000000000722e6d
7 ldc2 0x00000000006ad108
8 ldc2 0x00000000006af32d DtoCallFunction(Loc&, Type
, DValue
, ArrayBase) + 3469
9 ldc2 0x00000000006d736c CallExp::toElem(IRState
) + 412
10 ldc2 0x00000000007020a7 DtoArgument(Parameter_, Expression_) + 71
11 ldc2 0x00000000006af1dd DtoCallFunction(Loc&, Type_, DValue_, ArrayBase) + 3133
12 ldc2 0x00000000006f7c4b DtoNewClass(Loc, TypeClass
, NewExp_) + 491
13 ldc2 0x00000000006da4a8 NewExp::toElem(IRState_) + 1096
14 ldc2 0x00000000006d3504 Expression::toElemDtor(IRState_) + 68
15 ldc2 0x00000000007285c8 ReturnStatement::toIR(IRState_) + 1016
16 ldc2 0x000000000072819e CompoundStatement::toIR(IRState_) + 94
17 ldc2 0x00000000007052b9 DtoDefineFunction(FuncDeclaration_) + 2009
18 ldc2 0x0000000000745a49 Ir::emitFunctionBodies() + 57
19 ldc2 0x00000000006b5c66 Module::genLLVMModule(llvm::LLVMContext&, Ir_) + 806
20 ldc2 0x00000000005cf369 main + 6153
21 libc.so.6 0x00007fb9a6427ead __libc_start_main + 253
22 ldc2 0x00000000005dec8d
Aborted

from ldc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.