ed-precompiled_racc 1.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+ #
3
+
4
+ require 'mkmf'
5
+ require_relative '../../../lib/racc/info'
6
+
7
+ $defs << "-D""RACC_INFO_VERSION=#{Racc::VERSION}"
8
+ create_makefile 'racc/cparse'
@@ -0,0 +1,33 @@
1
+ #--
2
+ #
3
+ #
4
+ #
5
+ # Copyright (c) 1999-2006 Minero Aoki
6
+ #
7
+ # This program is free software.
8
+ # You can distribute/modify this program under the same terms of ruby.
9
+ # see the file "COPYING".
10
+ #
11
+ #++
12
+
13
+ unless Object.method_defined?(:__send)
14
+ class Object
15
+ alias __send __send__
16
+ end
17
+ end
18
+
19
+ unless Object.method_defined?(:__send!)
20
+ class Object
21
+ alias __send! __send__
22
+ end
23
+ end
24
+
25
+ unless Array.method_defined?(:map!)
26
+ class Array
27
+ if Array.method_defined?(:collect!)
28
+ alias map! collect!
29
+ else
30
+ alias map! filter
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,60 @@
1
+ #--
2
+ #
3
+ #
4
+ #
5
+ # Copyright (c) 1999-2006 Minero Aoki
6
+ #
7
+ # This program is free software.
8
+ # You can distribute/modify this program under the same terms of ruby.
9
+ # see the file "COPYING".
10
+ #
11
+ #++
12
+
13
+ module Racc
14
+
15
+ class DebugFlags
16
+ def DebugFlags.parse_option_string(s)
17
+ parse = rule = token = state = la = prec = conf = false
18
+ s.split(//).each do |ch|
19
+ case ch
20
+ when 'p' then parse = true
21
+ when 'r' then rule = true
22
+ when 't' then token = true
23
+ when 's' then state = true
24
+ when 'l' then la = true
25
+ when 'c' then prec = true
26
+ when 'o' then conf = true
27
+ else
28
+ raise "unknown debug flag char: #{ch.inspect}"
29
+ end
30
+ end
31
+ new(parse, rule, token, state, la, prec, conf)
32
+ end
33
+
34
+ def initialize(parse = false, rule = false, token = false, state = false,
35
+ la = false, prec = false, conf = false)
36
+ @parse = parse
37
+ @rule = rule
38
+ @token = token
39
+ @state = state
40
+ @la = la
41
+ @prec = prec
42
+ @any = (parse || rule || token || state || la || prec)
43
+ @status_logging = conf
44
+ end
45
+
46
+ attr_reader :parse
47
+ attr_reader :rule
48
+ attr_reader :token
49
+ attr_reader :state
50
+ attr_reader :la
51
+ attr_reader :prec
52
+
53
+ def any?
54
+ @any
55
+ end
56
+
57
+ attr_reader :status_logging
58
+ end
59
+
60
+ end
@@ -0,0 +1,16 @@
1
+ #--
2
+ #
3
+ #
4
+ #
5
+ # Copyright (c) 1999-2006 Minero Aoki
6
+ #
7
+ # This program is free software.
8
+ # You can distribute/modify this program under the same terms of ruby.
9
+ # see the file "COPYING".
10
+ #
11
+ #++
12
+
13
+ module Racc
14
+ class Error < StandardError; end
15
+ class CompileError < Error; end
16
+ end