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
""" | |
This is joke^Wenterprise code ab^H^Husing the ‘@’ operator to simulate | |
applying multiple decorators on a single line of code. | |
""" | |
# © 2022 wouter bolsterlee, licensed under SPDX BSD-3-Clause | |
import functools | |
# helper class and the magic ‘@stacked’ decorator itself |
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
/* | |
In the node.js intro tutorial (http://nodejs.org/), they show a basic tcp | |
server, but for some reason omit a client connecting to it. I added an | |
example at the bottom. | |
Save the following server in example.js: | |
*/ | |
var net = require('net'); |