Skip to content

Instantly share code, notes, and snippets.

View notJoon's full-sized avatar
🐾
Slacking like a pro

Lee ByeongJun notJoon

🐾
Slacking like a pro
View GitHub Profile
The Gno VM Instrumentation and Profiling System
Branch: https://github.com/notJoon/gno-core/tree/feat/profiler-v2
Abstract
========
This document describes the architecture, operation, and feature set
of the new profiling subsystem for the Gno Virtual Machine(VM). The
profiler is built on a general-purpose instrumentation layer that
@notJoon
notJoon / 20250215_gno_action_setup.md
Last active February 15, 2025 04:31
Run Gno Action On Your Repository

Run Gno Action On Your Repository

tl;dr

This article explains how to set up a CI environment for Gno projects using GitHub Actions and Docker. By following this guide, you can:

  • Set up automated testing for your Gno projects
  • Create a containerized test environment
  • Run tests both locally and in CI pipeline

For a working example, check out this link.

@notJoon
notJoon / bcb_counter.go
Last active September 20, 2024 02:48
basic coverage block counter
package bcb
// CounterId is a unique identifier for a coverage counter.
type CounterId int
// ExprId is a unique identifier for an expression.
type ExprId int
// BcbCounter represents the coverage counter or counter expression associated with the
// basic coverage block node or edge.
@notJoon
notJoon / code_block_parser.go
Created June 25, 2024 07:13
parsing markdown file's fencced code block via tree-sitter
package doctest
import (
"context"
"fmt"
"go/parser"
"go/token"
"strings"
sitter "github.com/smacker/go-tree-sitter"
@notJoon
notJoon / struct.go
Last active January 4, 2024 07:37
byte slice go struct parser using regex
package json
import (
"regexp"
"strings"
)
type FieldMetaData struct {
Name string
Tag string
import sttp.client4._
import sttp.client4.ziojson._
import zio.{ZIO, ZIOAppDefault}
import zio.json._
import sttp.client4.httpclient.HttpClientSyncBackend
import ujson.Value
object DiscordWebhook extends ZIOAppDefault {
@notJoon
notJoon / http_server.scala
Created July 10, 2023 12:14
HTTP 서버 기능추가
import zio._
import zio.http.{Http, Request, Response, Status, _}
import zio.logging._
import java.time.LocalDateTime
import java.time.format.DateTimeFormatter
object Main extends ZIOAppDefault {
def getCurrentTime: ZIO[Any, Nothing, String] =
ZIO.succeed(LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")))
@notJoon
notJoon / function_parser.rs
Created June 3, 2023 16:26
basic rust function parser using peg
use peg;
/// Parse the name of the function, the name and type of the parameter, and the return type.
///
/// I did not consider the case that the type is generic. (Reason: lazy to do it)
peg::parser! {
grammar rust_parser() for str {
pub rule rust_parser() -> Function
= f:function() end_of_file() { f }
@notJoon
notJoon / binary_search.asm
Last active February 1, 2023 08:12
binary search in assembly (x86-64)
section .text
global search
; implementing binary search
search:
xor ecx, ecx
loop:
; set range: `[a, b]`
; if `a` and `b` are equal, then the range is empty
@notJoon
notJoon / quasiquotaion.hs
Created December 7, 2022 01:24
Implementation of quasiquotation in haskell
{-# START_FILE Expr.hs #-}
{-# LANGUAGE DeriveDataTypeable #-}
module Expr
( Exp(..)
, pExp
, parse
) where
import Control.Applicative ( (*>)
, (<$>)
, (<*)