origen_verilog 0.4.0 → 0.5.0
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.
- checksums.yaml +4 -4
- data/config/version.rb +1 -1
- data/lib/origen_verilog/parser.rb +9 -0
- data/lib/origen_verilog/top_level.rb +1 -0
- data/lib/origen_verilog/verilog/node.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 04b3e2c736fb06dd06fe0bbe6a4a4a163f2575a1
|
4
|
+
data.tar.gz: 0c8bedd2f0affdcbfda380df15c908526bdea19e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e1db9eb4f61f6a0da81ebc37413dfa29d7e65832ba7d238b3d7289e7d4a4075b3b9760fb803861f90ade87acb6fb84b87d497f23e82517a46d92209edf271401
|
7
|
+
data.tar.gz: 5e796d72ba3897164b6f3c8f8dbff605217444b9fbf8754c47e951f17514fed8127acdaea3ea180d1630e196eb82cb06d554266133a064e3583f93b494682323
|
data/config/version.rb
CHANGED
@@ -3,6 +3,15 @@ require 'origen_verilog/node'
|
|
3
3
|
module OrigenVerilog
|
4
4
|
class Parser
|
5
5
|
def self.parse_file(path, options = {})
|
6
|
+
if !File.exist?(path) && options[:source_dirs]
|
7
|
+
dir = Array(options[:source_dirs]).find do |dir|
|
8
|
+
File.exist?(File.join(dir, path))
|
9
|
+
end
|
10
|
+
path = File.join(dir, path) if dir
|
11
|
+
end
|
12
|
+
unless File.exist?(path)
|
13
|
+
fail "File could not be found in the current dir, or any of the source dirs: #{path}"
|
14
|
+
end
|
6
15
|
parse(File.read(path), options.merge(file: path))
|
7
16
|
end
|
8
17
|
|
@@ -68,7 +68,7 @@ module OrigenVerilog
|
|
68
68
|
unless type == :module_declaration
|
69
69
|
fail 'Currently only modules support the to_model method'
|
70
70
|
end
|
71
|
-
Origen.target.temporary = -> { TopLevel.new(ast:
|
71
|
+
Origen.target.temporary = -> { TopLevel.new(ast: self) }
|
72
72
|
Origen.load_target
|
73
73
|
end
|
74
74
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: origen_verilog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stephen McGinty
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-06-
|
11
|
+
date: 2018-06-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ast
|