Skip to content

Instantly share code, notes, and snippets.

View thelink2012's full-sized avatar

Denilson das Mercês Amorim thelink2012

View GitHub Profile
@thelink2012
thelink2012 / regex_perf_boost_vs_cxx11.cpp
Last active August 29, 2015 14:13
Measuring the performance difference between Boost.Xpressive versus C++11 regex.
#define USE_XPRESSIVE 0
#include <iostream>
#include <string>
#if USE_XPRESSIVE
#include <boost/xpressive/xpressive_dynamic.hpp>
using namespace boost::xpressive;
#else
#include <regex>
using std::regex;
using std::smatch;
// ==UserScript==
// @name Vermifugo BMS (Hue no tópico de Ciências)
// @description Excludes Brazillian Modding Studio posts by the specified user.
// @include *://brmodstudio.forumeiros.com/*-ciencia-e-tal
// @require https://gist.githubusercontent.com/thelink2012/65db658df10a4d94da17/raw/vermifugo-bms.js
// @grant none
// @run-at document-end
// @version 1.0.1
// ==/UserScript==
'''
Take IDB Functions Mangled Symbols (IDA Python Script)
by LINK/2012
This source code is offered for use in the public domain. You may
use, modify or distribute it freely.
This code is distributed in the hope that it will be useful but
WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
DISCLAIMED. This includes but is not limited to warranties of
'''
Rename IDB Functions Based on GCC v3 ABI Mangled Symbols (IDA Python Script)
by LINK/2012
This source code is offered for use in the public domain. You may
use, modify or distribute it freely.
This code is distributed in the hope that it will be useful but
WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
DISCLAIMED. This includes but is not limited to warranties of
// http://stackoverflow.com/questions/20337870/what-is-the-equivalent-of-system-diagnostics-debugger-launch-in-unmanaged-code
#ifndef __LAUNCH_WIN32_DEBUGGER__
#define __LAUNCH_WIN32_DEBUGGER__
#pragma once
#include <windows.h>
#include <string>
#include <sstream>
inline bool LaunchDebugger()
@thelink2012
thelink2012 / variant_match.hpp
Last active February 27, 2016 06:07
Variant Matching
// This is free and unencumbered software released into the public domain.
//
// Anyone is free to copy, modify, publish, use, compile, sell, or
// distribute this software, either in source code form or as a compiled
// binary, for any purpose, commercial or non-commercial, and by any
// means.
//
// In jurisdictions that recognize copyright laws, the author or authors
// of this software dedicate any and all copyright interest in the
// software to the public domain. We make this dedication for the benefit
@thelink2012
thelink2012 / dummy_pool.py
Created April 26, 2016 03:51
Dummy python multiprocessing pool (uses same process, same thread)
class AsyncResult:
def __init__(self, func, args, cb):
self.func = func
self.args = args
self.completion_cb = cb
def wait(timeout=None):
pass
def ready(timeout=None):
  • Feature Name: gta3sc-define
  • Start Date: 11/11/2016

Summary

Means of defining string constants within GTA3script files.

Motivation

@thelink2012
thelink2012 / 0000-ir2.md
Last active November 22, 2016 16:52
SCM-IR2 specification
  • Feature Name: SCM-IR2
  • Start Date: 03/11/2016

Knowledge of the SCM format is assumed.

Summary

This is a proposal of a intermediate language for the SCM bytecode.

  • Feature Name: commands-oat
  • Start Date: 11/11/2016

Knowledge of the SCM format is assumed.

Summary

Proposal for a means of compiling commands by associating them with hashes.