This file contains 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
$.ajaxTransport("+*", function( options, originalOptions, jqXHR ) { | |
if(jQuery.browser.msie && window.XDomainRequest) { | |
var xdr; | |
return { | |
send: function( headers, completeCallback ) { |
This file contains 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 | |
// Notice: Undefined property: Test::$data となる | |
class Test extends PHPUnit_Framework_TestCase | |
{ | |
function setUp() | |
{ | |
$this->data = array( | |
array(1, 1) | |
); | |
} |
This file contains 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 | |
error_reporting(E_ALL | E_STRICT); | |
class C | |
{ | |
public static $one = 1; | |
public $two = 2; | |
static function a() { echo "a\n"; } | |
function b() { echo "b\n"; } | |
} |
This file contains 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
ishida=# create function t(bool) returns bool as 'select true' language sql; | |
CREATE FUNCTION | |
ishida=# create aggregate exists_(*) (sfunc = t, stype = bool, initcond = false); | |
CREATE AGGREGATE | |
ishida=# select exists_(*) from pg_user; | |
exists_ | |
--------- | |
t | |
(1 row) |
This file contains 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
$ find path_to_sourcedir/ -name '*.php' > cscope.files | |
$ cscope -b | |
$ cat ~/.vimrc | |
... | |
if has('cscope') | |
nnoremap <Leader>s :<C-u>scs find s <C-R>=expand("<cword>")<CR><CR> | |
nnoremap <Leader>g :<C-u>scs find g <C-R>=expand("<cword>")<CR><CR> | |
nnoremap <Leader>c :<C-u>scs find c <C-R>=expand("<cword>")<CR><CR> | |
nnoremap <Leader>t :<C-u>scs find t <C-R>=expand("<cword>")<CR><CR> |
This file contains 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
*** gosu.cmd.org Wed Nov 10 07:36:46 2010 | |
--- gosu.cmd Wed Nov 10 07:36:59 2010 | |
*************** | |
*** 21,28 **** | |
set _G_ROOT_DIR=%~dp0 | |
set _G_CLASSPATH= | |
! FOR /R %_G_ROOT_DIR%\..\jars %%G IN (*.jar) DO set _G_CLASSPATH=!_G_CLASSPATH!;%%G | |
! FOR /R %_G_ROOT_DIR%\..\ext %%G IN (*.jar) DO set _G_CLASSPATH=!_G_CLASSPATH!;%%G | |
This file contains 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 | |
$arr = array(1); | |
function &a() { | |
global $arr; | |
return $arr[]; | |
} | |
var_dump(a(), $arr); | |
var_dump(a(), $arr); | |
var_dump(a(), $arr); |
This file contains 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
syntax on | |
filetype plugin indent on | |
set tabstop=4 | |
set shiftwidth=4 | |
set noexpandtab | |
set ambiwidth=double | |
set t_Co=256 | |
set listchars=tab:^\ ,trail:< | |
set list |
This file contains 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 -r 'echo "foo" . 2 * 5, "\n";' | |
foo10 | |
$ php -r 'echo "foo" . 2 + 5, "\n";' | |
5 | |
$ php -r 'var_dump(true <> 0 > 1);' | |
bool(true) | |
$ php -r 'var_dump(true != 0 > 1);' | |
bool(true) | |
$ php -r 'var_dump((true <> 0) > 1);' |
This file contains 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
ishida=# create function any_eq (anyelement, anyelement) returns boolean language sql as 'select $1 = $2'; | |
CREATE FUNCTION | |
ishida=# create operator == (procedure = any_eq, leftarg=anyelement, rightarg=anyelement); | |
CREATE OPERATOR | |
ishida=# select 1+2 == 3; | |
?column? | |
---------- | |
t | |
(1 row) |
NewerOlder