Skip to content

Releases: dtolnay/cxx

1.0.16

11 Dec 22:16
1.0.16
38f6fe2
Compare
Choose a tag to compare
  • Add Vec capacity accessor (#565) and copy constructor and copy assignment operator (#566)
  template <typename T>
  class Vec final {
    ...
+   Vec(const Vec &);

+   Vec &operator=(const Vec &);

+   size_t capacity() const noexcept;
  };

1.0.15

11 Dec 22:15
1.0.15
2b3117f
Compare
Choose a tag to compare
  • Support shared_ptr of primitives, such as SharedPtr<u32> (#562)

1.0.14

10 Dec 20:30
1.0.14
a7b2b30
Compare
Choose a tag to compare
  • Support Vec<T> where T is a shared struct from a different bridge module (#535)
  • Support explicit impls impl Vec<T> {} and impl Box<T> {} (#542, #555)
  • Fix missing imports when generating C++ std::hash template specialization via #[derive(Hash)] (#556, #557)
  • Respect class-specific member operator new in the implementation of UniquePtr::new (#553)
  • Support reuse of non-POD shared types by value across bridge modules (#551, #559, #560)

1.0.13

10 Dec 20:24
1.0.13
c9e14fb
Compare
Choose a tag to compare
  • Fix a unique_ptr import in bridge modules that involve CxxVector but not UniquePtr (#548)

1.0.12

04 Dec 20:55
1.0.12
56f78f3
Compare
Choose a tag to compare
  • impl Debug for CxxVector<T> (#540)

  • Support parsing empty value for namespace attribute

    #[cxx::bridge(namespace = "some::path")]
    mod ffi {
        #[namespace = ""]
        struct InGlobalNamespace {...}  // exposed at ::InGlobalNamespace
    
        // everything else would be under ::some::path
    }

1.0.11

03 Dec 20:33
1.0.11
7297d74
Compare
Choose a tag to compare
  • Upgrade rust::Vec<T>'s iterator category from "forward iterator" to "random access iterator" to allow sorting and other random iteration (#538, thanks @mindv0rtex)

1.0.10

02 Dec 18:41
1.0.10
e58f3a0
Compare
Choose a tag to compare
  • Add cxx::SharedPtr<T>, a binding for C++ std::shared_ptr (#536)

1.0.9

01 Dec 23:05
1.0.9
9bbbe5f
Compare
Choose a tag to compare
  • Support derive(PartialOrd, Ord) on shared enums

  • Add non-const indexing overloads for rust::Vec<T> in C++: https://cxx.rs/binding/vec.html

      const T &operator[](size_t n) const noexcept;
      const T &at(size_t n) const;
      const T &front() const;
      const T &back() const;
    
    + T &operator[](size_t n) noexcept;
    + T &at(size_t n);
    + T &front();
    + T &back();

1.0.8

30 Nov 08:24
1.0.8
0b933de
Compare
Choose a tag to compare
  • Add comparison operators (==, !=, <, <=, >, >=) on rust::Str and rust::String (#531)

  • Add a constructor for rust::Vec<T> taking a std::initializer_list<T> (#533)

    rust::Vec<rust::String> vec = {"good", "stuff"};

1.0.7

29 Nov 22:59
1.0.7
45e4a80
Compare
Choose a tag to compare
  • Allow associated methods of the same name on different types in the same bridge (#471)