1. 09 Jan, 2015 9 commits
    • Kevin Modzelewski's avatar
      Large refactor for basic tp_alloc support · 0c20808b
      Kevin Modzelewski authored
      Use operator new() to get access to tp_alloc in a C++-ish way.
      
      Instead of passing the object's class to the constructor, pass
      it to new().  We need to do this since the class gets to pick how
      the object gets allocated, including how large it will end up being.
      
      Unfortunately it looks like defining an operator new on a subclass
      hides the operator new from a superclass, even if they have different
      signatures.  Macros to the rescue.
      0c20808b
    • Kevin Modzelewski's avatar
      Add "noexcept" specifications to all C API endpoints · 91321622
      Kevin Modzelewski authored
      Add a PYSTON_NOEXCEPT define that gets defined to "noexcept" in C++ mode,
      and to the empty string in C mode.
      
      I don't think 'extern "C"' implies noexcept.
      
      This is partly for better performance when we know that a function cannot throw
      an exception, but also as an annotation for us since the exception model is
      the main difference between C land and Pyston land.
      
      Vim substitution: %s/\(\<PyAPI_FUNC\>(.*).*(\([^)]\|\n\)*)\);/\1 PYSTON_NOEXCEPT;/gc
      - This will catch almost all cases, except for functions not marked with PyAPI_FUNC
        and function definitions that have extra paretheses (in comments, usually)
      91321622
    • Kevin Modzelewski's avatar
      Merge branch 'capi_subclassing' · 97b5b389
      Kevin Modzelewski authored
      97b5b389
    • Kevin Modzelewski's avatar
      e5a0e465
    • Kevin Modzelewski's avatar
      39dbe4fd
    • Kevin Modzelewski's avatar
      Ok it runs! · fa2942ae
      Kevin Modzelewski authored
      fa2942ae
    • Kevin Modzelewski's avatar
      Add some more CPython stuff · 9b45e675
      Kevin Modzelewski authored
      We're starting to have more functionality from CPython than we
      wrote ourselves -- I think this is a good thing, but we should switch
      Pyston code to calling it rather than supporting duplicates.
      
      After I finish adding this stuff I'll try to clean things up a bit.
      9b45e675
    • Kevin Modzelewski's avatar
      Add more CPython code · cfb1045a
      Kevin Modzelewski authored
      cfb1045a
    • Kevin Modzelewski's avatar
      Add a bunch more C API stuff · c7c10250
      Kevin Modzelewski authored
      Most involved was the recursion checking stuff: switch to
      providing the C API thread state rather than our internal
      one, since they are mostly the same.
      
      The recursion checking code doesn't mean much while most stuff
      doesn't use it, but hey at least it's supported now.
      c7c10250
  2. 08 Jan, 2015 24 commits
  3. 07 Jan, 2015 7 commits