From 9eba0c7decb383e3ef73a3fee375e725442cde56 Mon Sep 17 00:00:00 2001 From: murphy Date: Mon, 19 Oct 2009 17:34:39 +0000 Subject: Updating scanners: Ruby 1.9 warnings, KINDS_NOT_LOC * Also, DATABASE is a SQL keyword. --- lib/coderay/scanners/sql.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/coderay/scanners/sql.rb') diff --git a/lib/coderay/scanners/sql.rb b/lib/coderay/scanners/sql.rb index d889be5..2b21c79 100644 --- a/lib/coderay/scanners/sql.rb +++ b/lib/coderay/scanners/sql.rb @@ -6,7 +6,7 @@ module CodeRay module Scanners register_for :sql RESERVED_WORDS = %w( - create table index trigger drop primary key set select + create database table index trigger drop primary key set select insert update delete replace into on from values before and or if exists case when then else as group order by avg where @@ -35,7 +35,7 @@ module CodeRay module Scanners add(PREDEFINED_FUNCTIONS, :predefined). add(DIRECTIVES, :directive) - ESCAPE = / [rbfnrtv\n\\\/'"] | x[a-fA-F0-9]{1,2} | [0-7]{1,3} | . /mx + ESCAPE = / [rbfntv\n\\\/'"] | x[a-fA-F0-9]{1,2} | [0-7]{1,3} | . /mx UNICODE_ESCAPE = / u[a-fA-F0-9]{4} | U[a-fA-F0-9]{8} /x STRING_PREFIXES = /[xnb]|_\w+/i -- cgit v1.2.1