Git Product home page Git Product logo

Comments (6)

Killili avatar Killili commented on June 2, 2024 2

Part of why i didnt fix it after tracking it down is that i could not explain why that change happend and wanted to take a closer look or have someone that knows why to tell me why ;).

And without #96 its hard to write a test to check for that in the future so i guess that's a plus point for #96 already.

As i wrote the initial Prepared statement implementation im all for the "breaking" change that restores the behavior outlined in the README, i dont see it a breaking change its a bugfix for undefined behavior.

I do have some time now and would fix it that way if its ok with you.

from sqlite_modern_cpp.

zauguin avatar zauguin commented on June 2, 2024

I see four ways to fix this:

We can delete the reset() calls from extract and extract_single_value. Then the user has to reset on his own, which is what the README says anyway. This would be a semi-breaking change.

To avoid breaking existing code, we could keep the reset and manually set execution_started = true; again afterward.

On the other hand I do not really know why reset sets execution_started = false; in the first place.
I can not think of any reason why somebody would want to explicitly reset a statement and use implicit execution afterward. If we remove this, we have a breaking change too.

We can use execution_started or a new flag to track the reset status of the query.
Then reset() as a public interface could be deprecated and the library would be a bit easier to use.

I will try to prepare a pull request for the last approach. What do you think?

from sqlite_modern_cpp.

Killili avatar Killili commented on June 2, 2024

#97 will fix this but Travis broke, anyone got a clue about that?

from sqlite_modern_cpp.

zauguin avatar zauguin commented on June 2, 2024

I have restarted the Travis build, but the main problem is, that in the prepared statement test we assume that _extract* resets the statement.

from sqlite_modern_cpp.

Killili avatar Killili commented on June 2, 2024

hm thats bad, i will take a look in a moment.

from sqlite_modern_cpp.

zauguin avatar zauguin commented on June 2, 2024

Fixed by #98

from sqlite_modern_cpp.

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.