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
fe1cf5d allow explicit casts from enum to floating point numbers | |
42f91ab AST implementation relying on ctor instead of FormatterServices.GetUninitializedObject | |
72ad7f2 Use Boo.Lang.Compiler.Ast.ExceptionHandler explicitly. It conflicts with System.Reflection.Emit.ExceptionHandler in .NET 4.5 | |
6be232a Use ctor instead of FormatterServices.GetUninitializedObject since this is not supported on some platforms also, do not try to instantiate abstract classes | |
28859cb Include readme file for booi new features | |
5b050d4 Refactored booi to use the command line parser from Boo.Lang.Useful | |
397ce62 fix handling of callable expressions operands in conditional expressions | |
59169f8 fall back to regular reflection when accessing literal fields (fixes case 506498) | |
cf075f1 fix handling of generators that yield null (fixes case 494359) | |
7f53947 freeze AssemblyVersion at 2.0.9.5 to avoid breaking backwards compatibility with existing binaries |
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
""" | |
Diagnostics system based on the one from clang | |
http://clang.llvm.org/diagnostics.html | |
http://clang.llvm.org/docs/InternalsManual.html#the-diagnostics-subsystem | |
http://clang.llvm.org/doxygen/Diagnostic_8h_source.html | |
A DiagsEngine will be associated with the the CompilerContext and made | |
available to all the compiler components, including meta programming | |
extension points (macros, ast attributes, ..). The idea is that an |
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
# Registers a hook when changing directory to find out the | |
# local pyenv version in it. Exporting it as PYENV_LOCAL_VERSION. | |
# | |
# Note that it's meant to only detect those directories using a .python-version | |
# | |
update-pyenv-local-version() { | |
# This will return something like "my-version (set by /path/to/.python-version)" | |
local version="`pyenv version`" | |
if [[ $version == *.python-version* ]]; then |
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
# | |
# DrSlump custom theme. | |
# | |
# Authors: | |
# Iván -DrSlump- Montes <[email protected]> | |
# | |
# Define functions for ZLE that activate on mode change | |
function zle-line-init zle-keymap-select { | |
local iterm_vert='\e]50;CursorShape=1\x7' |
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
#!/bin/sh | |
pyenv virtualenv "$1" | |
echo "Entering a new shell session with version '$1'" | |
echo "Press ctrl+d or exit to terminate it" | |
export PYENV_VERSION="$1" | |
$SHELL |
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 Boo.Lang.Compiler.Ast | |
def Method1(x, y): | |
print 'Method1', x, y | |
def Method2(x, y, z): | |
print 'Method2', x, y, z | |
macro BindArg(expr as Expression): | |
for fn in ('Method1', 'Method2'): |
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
class CfgParser: | |
def __init__(self, src): | |
self.src = src | |
self.idx = 0 | |
def rowcol(self, ofs=None): | |
ofs = self.idx if ofs is None else ofs | |
lines = self.src.split('\n') | |
accum = 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
""" | |
Protocol should be compatible with Nailgun (http://www.martiansoftware.com/nailgun/protocol.html) | |
""" | |
namespace boodaemon | |
from System import UInt32 | |
from System.IO import BinaryReader, BinaryWriter | |
from System.Net.IPAddress import NetworkToHostOrder, HostToNetworkOrder | |
from System.Text import ASCIIEncoding |
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
<?php | |
class RectanglePacking { | |
private $root = array(); | |
private $usedHeight = 0; | |
private $usedWidth = 0; | |
function __construct($width, $height) { |
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
def djb2(data as string): | |
""" Computes a 32bit hash using the djb2 algorithm """ | |
payload = System.Text.Encoding.ASCII.GetBytes(data) | |
result as uint = 5381 | |
for ch in payload: | |
unchecked: | |
result = result * 33 + ch | |
return result & 0xffffffff |