BOAST 1.3.1 → 1.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ea64b71758e5e5a415024b05dffe731bf990a1ff
4
- data.tar.gz: 6ecb5d7acdae700d5e9521491e3dd71ef751e550
3
+ metadata.gz: ce1471079358a166a828d428d014c785ac0a6b08
4
+ data.tar.gz: a9b317526e6589ee928c41fa4f78b469a0d0a1b7
5
5
  SHA512:
6
- metadata.gz: c827fa7966599f2f807f1f123c2b5a0781260092701d63767da7b75638142ab062b5469f1d14c4d760e1c11f3f693f66fadb085d6a494d5f64188de050433888
7
- data.tar.gz: bbef18791ef66fd3b25ad9aaf7b75892e169204b5bb4fbe1da82eb43286b968c7da2e6cec46914aff6a072e27e203f05fe998084657e9d6dd87d86ac3cefe09e
6
+ metadata.gz: ff7690a6d81dd4d1b1c258d65da70ea326532a2968c618f471c83faf8ddb21dab9602156a6b495f06aca1cc3adfcd7bf0b76a6f4b32aa3983e182b0a535f8f45
7
+ data.tar.gz: 27107abb8e7166fac2593b2e78b5275f44bcbf54be4b065d2c024cf9ab6e9b5070bb971fdf09b39a491aafe1b4cf4a41aeebcfc96f91c43c891f8f688cef2fb1
data/BOAST.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'BOAST'
3
- s.version = "1.3.1"
3
+ s.version = "1.3.2"
4
4
  s.author = "Brice Videau"
5
5
  s.email = "brice.videau@imag.fr"
6
6
  s.homepage = "https://github.com/Nanosim-LIG/boast"
@@ -70,8 +70,16 @@ module BOAST
70
70
  private
71
71
 
72
72
  def to_s_fortran
73
+ indexes_dup = []
74
+ @source.dimension.each_with_index { |d,i|
75
+ if d.size.nil? and get_array_start != 1 then
76
+ indexes_dup.push( @indexes[i] - d.start + 1 )
77
+ else
78
+ indexes_dup.push( @indexes[i] )
79
+ end
80
+ }
73
81
  s = ""
74
- s += "#{@source}(#{@indexes.join(", ")})"
82
+ s += "#{@source}(#{indexes_dup.join(", ")})"
75
83
  return s
76
84
  end
77
85
 
@@ -190,9 +190,14 @@ module BOAST
190
190
  s = indent + to_s_fortran
191
191
  s += "\n"
192
192
  increment_indent_level
193
- parameters.each { |p|
194
- p.type.define if p.type.kind_of? CStruct
193
+ tmp_buff = StringIO::new
194
+ push_env( :output => tmp_buff ) {
195
+ parameters.each { |p|
196
+ p.type.define if p.type.kind_of? CStruct
197
+ }
195
198
  }
199
+ tmp_buff.rewind
200
+ s += tmp_buff.read
196
201
  s += indent + "integer, parameter :: wp=kind(1.0d0)"
197
202
  output.puts s
198
203
  constants.each { |c|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: BOAST
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.1
4
+ version: 1.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brice Videau