Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,14 @@ zig-cache/
*.segment


node_modules
/build
/.svelte-kit
/package
.env
.env.*
!.env.example
.vercel
.output
vite.config.js.timestamp-*
vite.config.ts.timestamp-*
30 changes: 14 additions & 16 deletions c-string/cstring.c
Original file line number Diff line number Diff line change
@@ -1,28 +1,26 @@
#include "cstring.h"

typedef struct s8 {
u8* buf;
size len;
u8 *buf;
size len;
} s8;


s8 s8Span(u8* begin, u8* end) {
s8 s;
s.buf = begin;
s.len = end - begin;
return s;
s8 s8Span(u8 *begin, u8 *end) {
s8 s;
s.buf = begin;
s.len = end - begin;
return s;
}

size s8Cmp(s8 a, s8 b) {
size len = a.len < b.len ? a.len: a.len;
for (size i = 0; i < len; i++) {
size d = a.buf[i] - b.buf[i];
if (d != 0) {
return d;
}
size len = a.len < b.len ? a.len : a.len;
for (size i = 0; i < len; i++) {
size d = a.buf[i] - b.buf[i];
if (d != 0) {
return d;
}
return a.len - b.len;
}
return a.len - b.len;
}


// add tests
2 changes: 1 addition & 1 deletion ebpf-cilium-golang-vfs-read-latency/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/BruceChen7/case-study/ebpf-cilium-golang-vfs-read-latency

go 1.21.0
go 1.21

require (
github.com/cilium/ebpf v0.11.0 // indirect
Expand Down
2 changes: 1 addition & 1 deletion go-context/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/BruceChen7/case-study/go-context

go 1.21.0
go 1.21

require github.com/stretchr/testify v1.8.4

Expand Down
12 changes: 12 additions & 0 deletions review/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
.DS_Store
node_modules
/build
/.svelte-kit
/package
.env
.env.*
!.env.example
.vercel
.output
vite.config.js.timestamp-*
vite.config.ts.timestamp-*
1 change: 1 addition & 0 deletions review/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
engine-strict=true
1 change: 1 addition & 0 deletions review/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
## my todo list
Loading