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
| import SwiftUI | |
| import AVKit | |
| struct VideoPlayerControls: View { | |
| let player: AVPlayer | |
| @Binding var currentTime: CGFloat | |
| var height: CGFloat = 50 |
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
| function switchgo() { | |
| version=$1 | |
| if [ -z $version ]; then | |
| echo "Usage: switchgo [version]" | |
| return | |
| fi | |
| if ! command -v "go$version" > /dev/null 2>&1; then | |
| echo "version does not exist, download with: " | |
| echo " go get golang.org/dl/${version}" |
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
| $ cat test.js | |
| function foo () { while (true) { } } | |
| function bar () { return foo(); } | |
| bar(); | |
| $ node test.js & | |
| $ gdb attach $(pidof node) | |
| 0x00000bf778c63d5f in ?? () | |
| (gdb) b v8::internal::Runtime_StackGuard | |
| Breakpoint 1 at 0x84a1f0 | |
| (gdb) print 'v8::V8::TerminateExecution'(0) |
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
| package main | |
| import ( | |
| "database/sql" | |
| "fmt" | |
| "net/url" | |
| "os" | |
| "reflect" | |
| "regexp" | |
| "strconv" |
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
| #!/usr/bin/env node | |
| const fs = require('fs'); | |
| const path = require('path'); | |
| const execSync = require('child_process').execSync; | |
| if (process.argv.length < 3) { | |
| console.log(`node ${path.relative('.', process.argv[1])} [DevToolsProfile]`); | |
| process.exit(1); | |
| } | |
| let traceFile = path.resolve(process.argv[2]) |
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
| To benchmark: | |
| go test -bench=".*" > machine_description.txt |
NewerOlder