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
const result = await fetch('https://some-place/some/path) | |
.then( | |
res => { | |
doSomethingComplicatedWith(res) | |
}, | |
err => { | |
console.log('Failed to fetch') | |
} | |
) |
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
#include <gtk/gtk.h> | |
int main(int argc, char *argv[]) { | |
GtkWidget *view; | |
GtkTextBuffer *buffer; | |
GtkWidget *window; | |
GdkDisplay *display; | |
GdkScreen *screen; | |
GtkCssProvider *provider; |
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
# Script to be used with gdb to trace changes to the maps file as Node.js | |
# performs mmaps. | |
import io | |
import os | |
import sys | |
import gdb | |
import shutil | |
import subprocess |
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
set pagination off | |
set breakpoint pending on | |
set style enabled off | |
set environment NODE_ENV=production | |
define domaps | |
shell echo "*** Start Event ***" | |
bt 10 | |
python gdb.execute('finish'); | |
shell echo "*** End Event *****" | |
continue |
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
class FinishMapsBreak (gdb.FinishBreakpoint): | |
def stop(self): | |
gdb.write('----------- End Event ------------\n') | |
gdb.flush() | |
return False | |
def out_of_scope(self): | |
return self.stop() | |
class MapsBreak (gdb.Breakpoint): |
| Parent Class | Subclasses |
|---|---|---|
| | [Napi::Boolean
][], [Napi::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
> const x = new Error(); | |
undefined | |
> const vm = require('vm'); | |
undefined | |
> vm.runInNewContext; | |
[Function: runInNewContext] | |
> vm.runInNewContext('x instanceof Error'); | |
Thrown: | |
evalmachine.<anonymous>:1 | |
x instanceof Error |
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
const addon = require('bindings')('addon'); | |
addon.receiveModule('fs', require('fs')); | |
addon.receiveModule('crypto', require('crypto')); | |
console.log(addon.sendModule('fs') === require('fs')); | |
console.log(addon.sendModule('crypto') === require('crypto')); |
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
host mac-node-ci | |
Hostname 207.254.58.162 | |
Port 10005 | |
User administrator | |
Cipher aes128-ctr |
NewerOlder