Code Monkey home page Code Monkey logo

Comments (6)

dlbeer avatar dlbeer commented on September 13, 2024

Yes, you will need a compiler that supports C99 to build it. If you're building on Windows then you might want to consider MinGW. You will likely also need to modify the Makefile, and you won't be able to build the demo program (which is Linux-only).

from quirc.

kaworu avatar kaworu commented on September 13, 2024

@dlbeer any consideration for dropping VLA as their support is optional in C11?

from quirc.

dlbeer avatar dlbeer commented on September 13, 2024

from quirc.

kaworu avatar kaworu commented on September 13, 2024

No idea about VC++ to be honest, I'm kind of hijacking this issue because I feel uneasy with VLA as they are seldom used in other projects and also are optional in C11.

alloca(3) isn't a big improvement as failure cannot be easily checked (e.g. the GNU man page say that on failure it can UB). I feel like a library should be as robust as possible, and neither VLA nor alloca(3) fit the bill. Allocating on the heap (i.e. malloc(3)) should be safer as we don't have any control on how deep the stack is, its limit, and q->w and will come with the usual cost of having to free the memory explicitely.

As for VC++, the situation may improve. While Microsoft has ignored C for long, they've ported OpenSSH to Windows and provide a Linux compatibility now. I think it has/will require them to support some C99 features (and maybe C11), so let's wait and see.

from quirc.

dlbeer avatar dlbeer commented on September 13, 2024

from quirc.

kaworu avatar kaworu commented on September 13, 2024

Agreed it seems to be the way to go after a quick look. I'll happily work on a patch and PR.

from quirc.

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.