This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <vector> | |
#include <functional> | |
#include "Signal.h" | |
template<typename ...Arguments> | |
void Signal<Arguments...>::connect(std::function<void (Arguments...)> listener) { | |
listeners.push_back(listener); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
inline constexpr bool isSpecialScheme(const char* scheme) { | |
return scheme == "ftp" || scheme == "file" || scheme == "gopher" || scheme == "http" || scheme == "https" || scheme == "ws" || scheme == "wss"; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Use gcc to compile | |
CC = gcc | |
# wildcard allows you to use * to select multiple files on a directory | |
# $(wildcard gen/logic/*.c) will sellect all files inside gen/logic/ that end with .c | |
SOURCE_FILES := $(wildcard gen/logic/*.c) $(wildcard gen/display/*.c) $(wildcard man/*.c) | |
# Now, all object files are stored right where source files are. | |
# This prevents having trouble when multiple files have the same name but they | |
# are in different directories. Resulting with .o files with the same name | |
# inside the obj/ directory. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use std::char; | |
type Board = [[char; 3]; 3]; | |
static BOARD: Board = [ | |
['C', 'B', 'X'], | |
['A', 'A', 'A'], | |
['N', 'N', 'T'] | |
]; |
OlderNewer