turn the function for creating new types (or type constructors) into a DOPE function
This commit is contained in:
parent
d8ca2f3999
commit
a0e3aa0cb3
12 changed files with 112 additions and 58 deletions
|
|
@ -1,7 +1,7 @@
|
|||
// The functions are only defined here. For their types, see lib/symbol.js
|
||||
|
||||
// The point of having an explicit constructor for SymbolT, is that we can later swap it out for something that is (de-)serializable.
|
||||
export const constructSymbol = name => Symbol(name);
|
||||
// Cannot turn the constructor into a DOPE function, because it is NOT PURE:
|
||||
// export const constructSymbol = name => Symbol(name);
|
||||
|
||||
export const getName = symbol => symbol.description;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue