Skip to content

Commit

Permalink
CI fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
snej committed Oct 12, 2023
1 parent e0432e1 commit 055725a
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 20 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Async/await gives you concurrency without the pitfalls of multithreading. You ca

How is that better than threads? It's safer and easier to reason about. The only places where concurrency happens are well-marked by the `co_await` and `co_yield` keywords. You don't need mutexes or atomic variables, and there are far fewer opportunities for race conditions or deadlocks. (There are performance benefits too: no expensive context switches, less stack usage.)

[Detailed documentation](docs/README.md) is being written.
[**Detailed documentation**](docs/README.md) is being written.

## Features

Expand Down Expand Up @@ -90,7 +90,7 @@ See also [demo_server.cc][tests/demo_server.cc], a simple HTTP and WebSocket ser
[![Build](https://github.com/couchbaselabs/crouton/actions/workflows/build.yml/badge.svg)](https://github.com/couchbaselabs/crouton/actions/workflows/build.yml)
This is new code, under heavy development! So far, it builds with Clang (Xcode 15) on macOS, GCC 12 on Ubuntu, and Visual Studio 17 2022 on Windows.
This is new code, under heavy development! So far, it builds with Clang (Xcode 14) on macOS, GCC 12 on Ubuntu, and Visual Studio 17 2022 on Windows.
The tests run regularly on macOS, and occasionally on Ubuntu (though not in CI.) Test coverage is very limited.
Expand All @@ -104,12 +104,12 @@ APIs are still in flux. Things get refactored a lot.
### Prerequisites:
- CMake
- Clang 15, Xcode 15, or GCC 12
- Clang 15, Xcode 14, or GCC 12
- zlib (aka libz)
#### on macOS:
- Install Xcode 15 or later, or at least the command-line tools.
- Install Xcode 14 or later, or at least the command-line tools.
- Install CMake; this is most easily done with [HomeBrew](https://brew.sh), by running `brew install cmake`
#### on Ubuntu Linux
Expand Down
2 changes: 1 addition & 1 deletion crouton.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1678,7 +1678,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "if which missing_includes.rb >/dev/null\nthen\n cd \"$SRCROOT\"\n missing_includes.rb -w --base include/Base.hh include src\nelse\n echo \"Script missing_includes.rb not found.\"\n echo \"You can get it from https://gist.github.com/snej/2672fe996d39752e23c471f6ed789958\"\nfi\n";
shellScript = "if which missing_includes.rb >/dev/null\nthen\n cd \"$SRCROOT\"\n missing_includes.rb -w --base include/util/Base.hh include src\nelse\n echo \"Script missing_includes.rb not found.\"\n echo \"You can get it from https://gist.github.com/snej/2672fe996d39752e23c471f6ed789958\"\nfi\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */
Expand Down
4 changes: 2 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
* [Errors](Errors.md)
* [Results](Results.md)
* Basic Coroutine Types
* [Coroutine Types](Coroutine Types.md)
* [Awaitable Types](Awaitable Types.md)
* [Coroutine Types](Coroutine%20Types.md)
* [Awaitable Types](Awaitable%20Types.md)
* Scheduling and Event Loops
* Logging
* [Publish And Subscribe](PubSub.md)
Expand Down
25 changes: 12 additions & 13 deletions include/util/Relation.hh
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,6 @@ namespace crouton::util {
class ToMany : private LinkedList<ToOne<Other,Self>>, private Child<Self> {
public:
using super = LinkedList<ToOne<Other,Self>>;
using ToOne = ToOne<Other,Self>;

/// Initializes an unconnected Child. This should be a member initializer of Self.
explicit ToMany(Self* self) :Child<Self>(self) { }
Expand All @@ -151,35 +150,35 @@ namespace crouton::util {

class iterator {
public:
explicit iterator(super::iterator i) :_i(i) { }
explicit iterator(typename super::iterator i) :_i(i) { }
Other& operator*() const {return *(_i->self());}
Other* operator->() const {return _i->self();}
iterator& operator++() {++_i; return *this;}
friend bool operator==(iterator const& a, iterator const& b) {return a._i == b._i;}
private:
super::iterator _i;
typename super::iterator _i;
};

iterator begin() {return iterator(super::begin());}
iterator end() {return iterator(super::end());}
iterator begin() {return iterator(super::begin());}
iterator end() {return iterator(super::end());}

void push_front(ToOne& link) {super::push_front(link); link._parent = this;}
void push_back(ToOne& link) {super::push_back(link); link._parent = this;}
void erase(ToOne& link) {super::erase(link); link._parent = nullptr;}
void push_front(ToOne<Other,Self>& link) {super::push_front(link); link._parent = this;}
void push_back(ToOne<Other,Self>& link) {super::push_back(link); link._parent = this;}
void erase(ToOne<Other,Self>& link) {super::erase(link); link._parent = nullptr;}

void clear() {deAdopt(); super::clear();}
void clear() {deAdopt(); super::clear();}

~ToMany() {deAdopt();}
~ToMany() {deAdopt();}

private:
friend ToOne;
friend ToOne<Other,Self>;

void adopt() {
for (ToOne& child : (super&)*this)
for (ToOne<Other,Self>& child : (super&)*this)
child._parent = this;
}
void deAdopt() {
for (ToOne& child : (super&)*this)
for (ToOne<Other,Self>& child : (super&)*this)
child._parent = nullptr;
}
};
Expand Down

0 comments on commit 055725a

Please sign in to comment.