Skip to content

Instantly share code, notes, and snippets.

View omo's full-sized avatar

Hajime Morrita omo

  • Mountain View, CA
View GitHub Profile
@omo
omo / tj.el
Created November 14, 2011 01:51
Open an octopress file in Emacs.
;; on setup
(setq tj-name "/Users/morrita/work/trivials/tj.rb")
;;
;; Create and open the journal file
;;
(when (bound-and-true-p tj-name)
(defun my-open-tj (given-title)
(interactive "MTitle: ")
(let ((welcome-page
@omo
omo / gist:1366887
Created November 15, 2011 11:48
Symbols to be covered.
Location is not found: _ZN3JSC10Heuristics17numberOfGCMarkersE
Location is not found: _ZN3JSC10Heuristics24opaqueRootMergeThresholdE
Location is not found: _ZN3JSC10JSFunction6s_infoE
Location is not found: _ZN3JSC11JSByteArray6s_infoE
Location is not found: _ZN3JSC12DateInstance6s_infoE
Location is not found: _ZN3JSC12JSGlobalData11jsArrayVPtrE
Location is not found: _ZN3JSC12JSGlobalData12jsStringVPtrE
Location is not found: _ZN3JSC12JSGlobalData14jsFunctionVPtrE
Location is not found: _ZN3JSC12JSGlobalThis6s_infoE
Location is not found: _ZN3JSC12RegExpObject6s_infoE
@omo
omo / gist:1619569
Created January 16, 2012 07:24
JSC exp list diff
--- ../beforeu.txt 2012-01-16 16:16:17.000000000 +0900
+++ ../afteru.txt 2012-01-16 16:16:51.000000000 +0900
@@ -114,6 +114,7 @@
T __ZN3JSC10JSFunction6createEPNS_9ExecStateEPNS_14JSGlobalObjectEiRKNS_10IdentifierEPFPvS2_ESA_
S __ZN3JSC10JSFunction6s_infoE
T __ZN3JSC10JSFunctionC1EPNS_9ExecStateEPNS_14JSGlobalObjectEPNS_9StructureE
+T __ZN3JSC10JSFunctionC2EPNS_9ExecStateEPNS_14JSGlobalObjectEPNS_9StructureE
T __ZN3JSC10throwErrorEPNS_9ExecStateENS_7JSValueE
T __ZN3JSC10throwErrorEPNS_9ExecStateEPNS_8JSObjectE
T __ZN3JSC11JSByteArray10putByIndexEPNS_6JSCellEPNS_9ExecStateEjNS_7JSValueE
@omo
omo / gist:1655408
Created January 22, 2012 04:04
/etc/hosts 追記分
127.0.0.1 plus.google.com
127.0.0.1 twitter.com
127.0.0.1 www.facebook.com
127.0.0.1 b.hatena.ne.jp
127.0.0.1 mixi.jp
/*
* Generated by dtrace(1M).
*/
#ifndef _TRACING_H
#define _TRACING_H
#include <unistd.h>
#ifdef __cplusplus
diff --git a/chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac.mm b/chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac.mm
index abb528d..9c174f9 100644
--- a/chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac.mm
+++ b/chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac.mm
@@ -218,7 +218,7 @@ NSAttributedString* OmniboxPopupViewMac::MatchText(
font.GetNativeFont(), NSFontAttributeName,
ContentTextColor(), NSForegroundColorAttributeName,
nil];
- NSString* rawEnDash = [NSString stringWithFormat:@" %C ", 0x2013];
+ NSString* rawEnDash = [NSString stringWithFormat:@" %C ", static_cast<wchar_t>(0x2013)];
@omo
omo / gist:1715443
Created February 1, 2012 06:12
JSC exp list diff updated.
--- beforeg.sym 2012-02-01 14:28:12.000000000 +0900
+++ afterg.sym 2012-02-01 14:29:05.000000000 +0900
@@ -117,9 +117,11 @@
T __ZN3JSC10JSFunction6createEPNS_9ExecStateEPNS_14JSGlobalObjectEiRKNS_10IdentifierEPFPvS2_ESA_
S __ZN3JSC10JSFunction6s_infoE
T __ZN3JSC10JSFunctionC1EPNS_9ExecStateEPNS_14JSGlobalObjectEPNS_9StructureE
+T __ZN3JSC10JSFunctionC2EPNS_9ExecStateEPNS_14JSGlobalObjectEPNS_9StructureE
T __ZN3JSC10throwErrorEPNS_9ExecStateENS_7JSValueE
T __ZN3JSC10throwErrorEPNS_9ExecStateEPNS_8JSObjectE
T __ZN3JSC11Interpreter13getStackTraceEPNS_12JSGlobalDataEiRN3WTF6VectorINS_10StackFrameELm0EEE
@omo
omo / AtomicString.cpp
Created February 8, 2012 07:32
AtomicString AtomicString::lower()
AtomicString AtomicString::lower() const
{
// Note: This is a hot function in the Dromaeo benchmark.
StringImpl* impl = this->impl();
if (UNLIKELY(!impl))
return *this;
RefPtr<StringImpl> newImpl = impl->lower();
if (LIKELY(newImpl == impl))
return *this;
return AtomicString(newImpl);
@omo
omo / gist:1822443
Created February 14, 2012 01:56
FrameTree.h inclusion list
narogoloth:alice morrita$ find Source/ -name "*.cpp" | xargs grep FrameTree
Source//WebCore/bindings/js/JSDOMWindowCustom.cpp:#include "FrameTree.h"
Source//WebCore/bindings/js/PageScriptDebugServer.cpp:#include "FrameTree.h"
Source//WebCore/bindings/v8/custom/V8DOMWindowCustom.cpp:#include "FrameTree.h"
Source//WebCore/dom/Document.cpp:#include "FrameTree.h"
Source//WebCore/editing/Editor.cpp:#include "FrameTree.h"
Source//WebCore/editing/FrameSelection.cpp:#include "FrameTree.h"
Source//WebCore/history/CachedFrame.cpp:#include "FrameTree.h"
Source//WebCore/history/CachedPage.cpp:#include "FrameTree.h"
Source//WebCore/history/PageCache.cpp:#include "FrameTree.h"
@omo
omo / handlebars.js
Created February 21, 2012 13:16
Handlebars.js AMD support
// src/amd/prologue.js
define(function() {
// lib/handlebars/base.js
/*jshint eqnull:true*/
var Handlebars = {};
Handlebars.VERSION = "1.0.beta.5";