This file contains 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
/** | |
* @headerfile Event.hpp | |
* @author COlda | |
* @copyright MIT | |
* @see https://gist.github.com/CCColda/e3d3410c2c816cf6e394f133884858c8 | |
*/ | |
#ifndef COLDA_EVENT_H | |
#define COLDA_EVENT_H |
This file contains 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
/** | |
* @brief Gives the Promise + non-Promise variant of a function | |
* @example MaybePromise<(x: number, y: string | number) => Date> = | |
* ((x: number, y: string | number) => Date) | ((x: number, y: string | number) => Promise<Date>) | |
* @author COlda | |
*/ | |
type MaybePromise<T extends (...args: any) => any> = T | (T extends (...args: infer A) => infer R ? (...args: A) => Promise<R> : never); |
This file contains 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
/** | |
* @typedef {{ | |
* vin: number, | |
* vout: number | |
* } & ({r1: number} | {r2: number})} TVoltageDividerParams | |
* | |
* @typedef {{ | |
* vin: number, | |
* vout: number, | |
* r: Set<number> | number[] |
This file contains 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
{-| | |
See: https://wiki.haskell.org/99_questions/1_to_10 | |
Author: CCCOlda 2020 | |
-} | |
module ListUtil where | |
-- || Describes a nested list structure | |
data NestedList a = Elem a | List [NestedList a] |